Hi there,
today i started to play around with Asterisk-java.
I have downloaded Version 0.1 from sourceforge.net and began to follow
the Tutorial.
I am running Asterisk 1.0.1.
One i dialed in the Asterisk Server, it connects to the succesfully to
the AGIServer, but wasn't able to map the name of the agi-script to the
Java Class.
I did some investigation in the source files and here are my results:
- From my Asterisk following line is sent:
agi_request: agi://10.3.4.12:1234/hello.agi
- In net.sf.asterisk.fastagi.AGIRequest.getScript() only network_script
is parsed -> changed this to request
- The RegExp was ^([^\\?]*)\\?(.*)$
I must admit i didn't really understood this and played a little bit
to make it match the script name -> agi://.*/(.*)$
Alright, i am assuming that agi:// will always be part of the url and
so far it brakes the there are parameters present.
I hope i am not forgetting something but i think that were all changes
that made Asterisk-java work for me.
The main question is now, if my Asterisk Version is too old, and the key
has changed from agi_request to agi_network_script.
Maybe someone can explain the original RegExp for me (if in fact this
really matches the URL as proposed in the turorial).
Hope to hear from anyone soon ;-)
Best Wishes ...
Tobias
|