alternative to flash shared objects

Gabriel T

im redesigning my web conference app, previsouly working with flash, with webrtc and websockets. while all real time communication is fine, i'm struggling on how to find an alternative to flash shared objects to store datas such as room state etc on the server. so far i'm doing it with ratchet socket server, but i still didnt find a way to reset room datas automatically when conference is finished (like wowza application instances dying by themselves when room is empty , then flushing all datas stored in shared objects)
does anybody has some ideas/recommandations to handle this problem ?

thank you for your help and suggestions


Staff member

1. WCS sends REST hooks on each user event (i.e. connection, disconnection, play stream, start stream, etc).
2. WCS allows to send arbitrary json data to REST hooks. So you can send an object {"name":"value"} and receive this object as REST hook on server side.
3. And finally WCS can deliver arbitrary json data object to connected browser using direct REST URL https://host:8888/rest-api/data/send {...}

Therefore you can implement a kind of shared objects but you need server-side programming for that.
1. User A sends arbitrary data
2. WCS sends REST hook /OnDataEvent {name:"value"}
3. Back-end sends REST request https://host:8888/rest-api/data/send {sessionId:'user-b-session-id',payload:{name:"value"}};
4. User B receives the data {name:"value"} in Session.ON_DATA event.

Here you can find REST docs:

Here you can find working implementation
This app uses room sub-API
As you can see it uses session.sendData() method.
So it looks like shared objects. You have a room and you can broadcast messages within the room.