Making some more progress - https://github.com/tomchristie/uvicorn I'll look into adding streaming HTTP request bodies next, and then into adding a websocket protocol.
I see that the consumer interface is part of the channels API reference, rather than part of the ASGI spec. Is the plan to eventually include the consumer interface as part of the ASGI spec, and make it more clearly separate to channels? > The ability to just plug in a callable/coroutine that gets called with messages as they arrive, and which provides you with channel names to listen on as an attribute This sort of interface is exactly what I'm looking for, yes. From my POV the consumer callable is the primary bit of interface, rather than the channel layers. The consumer interface as it currently stands *is* sufficient for writing alternative frameworks against, but it's possible that there could be a more limited, refined interface to be had here. (Eg. limiting the message argument to being something that contains only serializable data and channel interfaces.) What would be great would be to have *just* the ASGI consumer callable interface pulled into Django core, and have channels be one of the possible ways of deploying against that. > persist state somewhere outside the locals() of the function (as you'll still have separate coroutines for connect/receive/disconnect). I assume you'd use the name of the reply_channel as the key to the state there, right? Incidentally asyncio implementations have less of a requirement here, as you could write a single coroutine handler that's called on `connect`, and that can then can non-blocking reads to a channel for incoming data, and could support broadcast via an asyncio interface onto redis pub/sub. Cheers, Tom :) -- You received this message because you are subscribed to the Google Groups "Django developers (Contributions to Django itself)" group. To unsubscribe from this group and stop receiving emails from it, send an email to django-developers+unsubscr...@googlegroups.com. To post to this group, send email to django-developers@googlegroups.com. Visit this group at https://groups.google.com/group/django-developers. To view this discussion on the web visit https://groups.google.com/d/msgid/django-developers/02d36ad5-a41e-48e2-8ce0-1e5c64e4eea5%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.