[Asterisk-Dev] Adding extension information to queue log

Tilghman Lesher tilghman at mail.jeffandtilghman.com
Wed Aug 4 19:30:43 MST 2004


On Wednesday 04 August 2004 17:59, Ilia Alshanetsky wrote:
> I am trying to modify the app_queue.c to log the information
> regarding the extension/phone number of the person who has picked
> up the line. So far my attempts have yielded no results on no valid
> values. I've tried access the current extension via qe->chan->exten
> and several other structures.
>
> Could anyone please clarify how (if at all) this information can be
> accessed?

You can't, because in Asterisk, channels and extensions are distinct
entities; they aren't intrinsically tied together.  And in queuing,
it's the agent channel or physical channel to which the call is
delivered.  However, you could put lookups of channels to extensions
in the astdb, then do a lookup of the destination channel at the
appropriate time.

Another way to do it might be to set up the agents as local channels
(exten at context), then log the destination channel name.

-- 
Tilghman



More information about the asterisk-dev mailing list