javaasteriskasteriskami

Asterisk-java. Queues action


Help me please with the question:

I need to get information about the queue (the best option would be for a particular queue and all queues). I use the asterisk-Java 2.0.3 library. For information about a particular queue, I can send the action - QueueSummaryAction. To get all the queues I can use the AsteriskServer object and get the information using getQueues(). However, this information is slightly incomplete. In addition, I connect to the server Asterisk via telnet. And after doing the appropriate action (action: queues), I get a list of queues with pretty good information (see image).

image

I would like to somehow get this with the help of AMI and the implementation presented in this library. Can there be any analogy? For example, I'm interested in the number of calls, the number of responses, deductions (in image it's W:0, C:5, A:24, SL:100.0%, within 60s). But, unfortunately, I did not find a way to get such information. Part of the presented in the image, I can get, but I would like more (regarding the queue itself, not the queue members).

About my implementation. I create a new DefaultAsteriskServer. Next, I add my listeners (I will not describe them here).

public void build(String hostname, int port, String username, String password)
{
    asteriskServer = new DefaultAsteriskServer(hostname, port, username, password);
    asteriskServer.initialize();
    LOGGER.info("Asterisk server initialized");
}

public void addEventListener(ManagerEventListener eventListener)
{
    asteriskServer.getManagerConnection().addEventListener(eventListener);
}

Actually, that's all.

Thank you all in advance for your help.


Solution

  • You should issue manager action "COMMAND"

    In parameters you can put same request you show on your screen