Dear all,
I am using application Record() on a solution I have build and I observed a really weird behavior that is not aligned with the specifications of this function. Please have a look first at the logs below:
[Oct 15 11:43:06] VERBOSE[][] pbx.c: Executing [s@recording:11] Record("PJSIP/opensips-00000166", "/myPath/myFile.wav,3,180,ko") in new stack
[Oct 15 11:43:06] VERBOSE[][] file.c: <PJSIP/opensips-00000166> Playing 'beep.slin' (language 'en')
[Oct 15 11:46:06] VERBOSE[][] pbx.c: Executing [h@recording:1] GotoIf("PJSIP/opensips-00000166", "0?check_fax") in new stack
[Oct 15 11:46:06] VERBOSE[][] pbx.c: Executing [h@recording:2] GotoIf("PJSIP/opensips-00000166", "1?check_duration:abort_deposit") in new stack
[Oct 15 11:46:06] VERBOSE[][] pbx.c: Executing [h@recording:3] Set("PJSIP/opensips-00000166", "vmail_duration=0.000000") in new stack
Application Record() is called, in order to save wav to a specific file, using a silence of 3sec and maxduration of 180sec=3min. Additionally, options ko are used, in order to keep the recorded file upon hangup and exit when also ‘0’ is pressed.
According to the user and according to the logs from core network, this call was immediately disconnected when the ‘beep’ sound of Record() was heard.
However, at the logs we can observe that the Record() was not interrupted at hangup. However, recording continues and is stopped after 3 minutes (probably when maxduration was reached). Moreover, call flow execution goes to h extension, as if hangup was performed. Furthermore, I use a ‘sox’ command, in order to estimate the length of the recorded wav file and it takes a value of 0sec, as if nothing was recorded.
According to manual and according to all tests I have done so far, this behavior is unexpected.
In case hangup is detected, Record() should stop, STATUS turns to HANGUP and call flow execution goes to h extension.
In case no hangup is detected, Recording should stop if 3sec silence is detected, or if maxduration of 180sec is reached. At the latter case the corresponding recorded wav should not be of zero length, since recording was running for 180sec.
This issue is found only once. My major concern is that it could be an error that will be reproduced often, causing unexpected call flow execution.
The expertise of the community is really useful at this case. Are similar issues with Record() already reported? Do you think that this error could be easily reproduced? How could you justify such a behavior?
Thank you in advance for your time and interest.
Best Regards.