[Home]

Summary:ASTERISK-17213: Channel variables apparently not available as application arguments in features.conf application map
Reporter:Kenneth Shumard (kshumard)Labels:
Date Opened:2011-01-07 16:01:17.000-0600Date Closed:
Priority:MajorRegression?No
Status:Open/NewComponents:Features
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:
Description:It'd be great if the below worked in features.conf so that users could punch a feature code to have a message logged with the channel and time so issues could be debugged:

{noformat}
[applicationmap]
audioissuelog => 333,self/both,Log(NOTICE,Audio issue reported by ${CHANNEL} at ${STRFTIME(${EPOCH},,%F %T) !!)
{noformat}

I'd expect something like

{noformat}
[Jan  7 14:49:42] NOTICE[4290] Ext. 35: Audio issue reported by SIP/polycom-00000010 at 2011-01-07 14:49:42 !!
{noformat}

to be put in the log (which is what happens when I run the same command from the dialplan instead of features.conf), but what I actually see is

{noformat}
[Jan  7 14:25:04] NOTICE[2581] Ext. 53: Audio issue reported by ${CHANNEL} at ${STRFTIME(${EPOCH},,%F %T) !!
{noformat}

Apparently channel variables aren't interpreted when the application is called from features.conf's [applicationmap].

This is true regardless of which application I call. I also tried with Playback, with Set(AudioFile=tt-monkeys) in the dialplan and playbacktest => 444,self/both,Playback(${AudioFile}) in the [applicationmap] of features.conf, and the console told me

{noformat}
[Jan  7 14:54:11] WARNING[4679]: file.c:650 ast_openstream_full: File ${AudioFile} does not exist in any format
[Jan  7 14:54:11] WARNING[4679]: file.c:956 ast_streamfile: Unable to open ${AudioFile} (format 0x4 (ulaw)): No such file or directory
[Jan  7 14:54:11] WARNING[4679]: app_playback.c:476 playback_exec: ast_streamfile failed on SIP/xlite4-00000014 for ${AudioFile}
{noformat}

Calling Playback(${AudioFile}) from the dialplan worked as expected.

What would it take to make channel variables accessible from features.conf's [applicationmap]?

Comments: