Encapsulate handling of all Bokeh Protocol messages a Bokeh server may receive.
- class ProtocolHandler[source]#
A Bokeh server may be expected to receive any of the following protocol messages:
The job of
ProtocolHandleris to direct incoming messages to the right specialized handler for each message type. When the server receives a new message on a connection it will call
handlerwith the message and the connection that the message arrived on. Most messages are ultimately handled by the
ServerSessionclass, but some simpler messages types such as
SERVER-INFO-REQmay be handled directly by
Any unexpected messages will result in a
- async handle(message, connection)[source]#
Delegate a received message to the appropriate handler.
message (Message) – The message that was receive that needs to be handled
connection (ServerConnection) – The connection that received this message