Hi I am working in a symfony real time app using Ratchet Library, In my app I need to send some data to a specific user.And the only way to do this is to attach a symfony session object to each incoming Connection object. I have read the doc here but I can't understand it and how to make it work in symfony?
As the documentation states need to setup a non-native session handler to store your sessions i.e. in a database via PDO.
Then you need to configure Ratchet to use your session handler. If you're using ClankBundle you can read this documentation chapter.
来源:https://stackoverflow.com/questions/17558657/how-to-attach-a-symfony-session-with-the-connection-object-from-ratchet