Hi Walter
The part I am not understanding is how handle_request gets called and under
what circumstances.
The URL to your service must include it. Supose your
server-script is soap_service.lua and is (virtually) located at
your.server.name/cgilua_scripts. Thus, the URL to your service
would be: http://your.server.name/cgilua_scripts/soap_service.lua
CGILua will build the cgilua.POST table and run the script;
the script will register all objects and call handle_request() to
dispatch.
You wrote:
>>After doing that for every object, the server-script might call
handle_request():
>>soap.server.handle_request(cgilua.POST[1],
cgilua.servervariable("QUERY_STRING"))
Is handle_request registered by CGILua such that the above only gets invoked
when a SOAP request comes in from a client?
No, handle_request() will be invoked anyway. IIRC, handle_request
will show a standard page when there is no POST data, but I'm not sure.
How did you accomplish that?
I didn't :-(
Note that the handle_request code does not try to sort out whether a POST
was associated with a SOAP request, so presumably some higher-level
dispatching takes place to only allow SOAP requests to be presented
to handle_request.
There is no such thing.
Also, would the catalog-building routines (register_service_info and export)
be called once at initialization, or would the catalog be re-built on each
request?
Since the script is executed as a CGI script, it will rebuild
on each request.
BTW, our interesting application is digital IP cameras, which have a Web
server running in the on board CPU. We would like to use Xavante. SOAP is a
very important future direction for standards-based IP cameras.
If you are developing exclusively for Xavante, then you should
develop a specific handler for this service. I think it would allow the
script not to reinitialize everything to each request and maybe it could
be more restrictive as you mentioned above, but I am not sure how to do
it. Anyway, I think there are other people on this list which could help.
Regards,
Tomás_______________________________________________
Kepler-Project mailing list
[email protected]
http://lists.luaforge.net/cgi-bin/mailman/listinfo/kepler-project
http://www.keplerproject.org/