Given the lack of async Python drivers for most databases in Python 3, I
That's not a problem .. Twisted ADB will run code using blocking database drivers on a background thread pool:
want to write a component doing db queries and make RPC calls to it.
I also want to code an configuration system which will signal all
clients when a value has changed, using PUB/SUB.
One of my client is a WSGI process, coded using Werkzeug and Python 3.
Can I use it as a WAMP client ? If yes, how ? Cause I don't what to do
with the WAMP client main loop.
In general, since WSGI is synchronous, I can't see how a fully-fledged WAMP client would be able to run within the WSGI based code.
While Crossbar.io can host/run WSGI components:
you cannot directly mix WSGI with WAMP code.
Crossbar.io runs WSGI components on a background thread pool using Twisted Web WSGI container.
What you can do using that is call into the main thread
which would allow you to do (unacknowledged) Publish, but none of the others (Call, Register or Subscribe).
If no, is there an alternative ?
E.G : does a stateless HTTP transport for WAMP exists, using callbacks
URI ? If no, how can I code that (or at least find the informations to
do so) ?
We have started a "HTTP long-poll" based transport once for WAMP .. mainly for browsers lacking WebSocket support.
However, if your goal is to run that under (synchronous) WSGI, that won't work as you expect: serving HTTP long-poll using a synchronous HTTP server framework (WSGI) will bring the server down quickly.
Keeping open 1000 long-poll connections on a classical WSGI server will occupy 1000 threads.
My goal is to enventually have independant components that can run on
their own for dev, then on deployment, to hook them on crossbar.io.
But WSGI (PEP 3333) IMHO isn't the right substrate to base everything on .. in fact, WSGI is a dead end right now
Am 02.04.2014 10:52, schrieb Michel Desmoulin:
You received this message because you are subscribed to the Google
Groups "Autobahn" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to autobahnws+...@googlegroups.com
For more options, visit https://groups.google.com/d/optout.