Changes

Jump to: navigation, search

Loop/Architecture/Rooms

878 bytes added, 18:09, 16 March 2015
Updating Session State
In order to track room state for metric purposes, the client will also send a POST message to the "/rooms/{token}" endpoint whenever a state change occurs, according to the following state machine:
<center><graphviz format="png" renderer="dot">digraph loop_room_state { init; waiting; starting; sending; receiving; sendrecv; cleanup;  init->waiting [label="Sesssion.connectionCreated"] waiting->starting [label="Sesssion.connectionCreated"]  starting->receiving [label="Sesssion.streamCreated"] starting->sending [label="Publisher.streamCreated"]  receiving->sendrecv [label="Publisher.streamCreated"] sending->sendrecv [label="Session.streamCreated"]  sendrecv->receiving [label="Publisher.streamDestroyed\nif send count = 0"] sendrecv->sending [File:looplabel="Session.streamDestroyed\nif recv count = 0"]  sending-room>cleanup [label="Publisher.streamDestroyed\nif send count = 0"] receiving-state>cleanup [label="Session.png|center|Room streamDestroyed\nif recv count = 0"]  cleanup->waiting [label="Session State Diagram.connectionDestroyed\nif connection count = 1"] waiting->init [label="Session.connectionDestroyed"]}</graphviz></center>
Note that there are some exceptional transitions that are not shown; in particular, a "session.connectionDestroyed" event from any of the "starting", "sending", "receiving", or "sendrecv" states will cause a transition to "waiting."
Confirm
632
edits

Navigation menu