I'm looking to use fifo_record_template to specify uniquely named recording files. Here is the situation:<br><br>I'm using a fifo with on-hook members. I would like each fifo call to be recorded, with each recording-file named uniquely.<br>
<br>Thanks to some helpful IRC talk, I have learned that the following works well:<br>
<br><fifo name="Outside_Call@$${domain}" importance="0"><br> <member timeout="20" simo="1" lag="0">{fifo_record_template=$${base_dir}/recordings/my_recording.wav,fifo_member_wait=nowait}user/35351@$${domain}</member><br>
</fifo><br><br>However, this records each and every fifo call to the file (in my case):<br>/usr/local/freeswitch/recordings/my_recording.wav<br><br>Every new call overwrites the file.<br><br>Instead of a statically defined file name, I would like a unique file name for every fifo call.<br>
<br>I don't know how to make reference to channel variables in this definition. I tried the following, but it results in an error:<br><br><fifo name="Outside_Call@$${domain}" importance="0"><br>
<member timeout="20" simo="1" lag="0">{fifo_record_template=$${base_dir}/recordings/{${uuid}.wav,fifo_member_wait=nowait}user/35351@$${domain}</member><br>
</fifo><br><br>
The error I see on the CLI when a call goes into the FIFO is this: <br><br>2010-03-18 13:51:11.289448 [CRIT] switch_channel.c:759 Invalid data (${fifo_record_template} contains a variable)<br><br>It was also suggested to me that I escape the '$' character on the variable. Like this:<br>
<br><fifo name="Outside_Call@$${domain}" importance="0"><br>
<member timeout="20" simo="1" lag="0">{fifo_record_template=$${base_dir}/recordings/{\${uuid}.wav,fifo_member_wait=nowait}user/35351@$${domain}</member><br>
</fifo><br><br>This also resulted in:<br><br>2010-03-18 13:52:37.014742 [CRIT] switch_channel.c:759 Invalid data (${fifo_record_template} contains a variable)<br><br>The recording file doesn't get generated. <br>
<br>Any recommendations on using fifo_record_template to generate recording file names that are unique to each call? Is there a way to get channel variables to be evaluated and populate the value of fifo_record_template?<br>
<br>Or does fifo_record_template only support static values (meaning I'd have to do a record_session in dial plan?)?<br><br>Thanks for any feedback.<br>