-
1. Re: sendNowWith(RequestDispatcher) from server sends message to multiple browsers
jbrow May 1, 2012 7:35 AM (in response to jbrow)I'm using 2.0-SNAPSHOT, BTW.
-
2. Re: sendNowWith(RequestDispatcher) from server sends message to multiple browsers
cbrock May 1, 2012 10:13 AM (in response to jbrow)I think you're looking for this: https://docs.jboss.org/author/display/ERRAI/Message+Routing+Information
Also, ensure you understand about conversations: https://docs.jboss.org/author/display/ERRAI/Conversations
-
3. Re: sendNowWith(RequestDispatcher) from server sends message to multiple browsers
jbrow May 1, 2012 1:22 PM (in response to cbrock)Thanks, however I knew about that (and use it that way in other places). It would appear that "sendNowWith" and "sendGlobalWith" do the same thing. I guess I expected "sendNowWith" to only message those clients in the same session ID since the documentation makes a point that "sendGlobalWith" is for broadcasting.
-
4. Re: sendNowWith(RequestDispatcher) from server sends message to multiple browsers
cbrock May 1, 2012 1:48 PM (in response to jbrow)Yes, "sendGlobalWith" is a holdover from Errai 1.x and it will be documented as deprecated. It dates back to an older version of Errai in which conversations worked somewhat differently. Conversations have to do with the message itself, not how it is dispatched.
So a Message *is* conversational, or it *is* global. send() and sendGlobal() thus do the same thing. We never removed sendGlobal() in an effort not to break code, but our failing has been in not updating the JavaDoc and deprecating it. It is likely that it will be removed in Errai 3.x.
-
5. Re: sendNowWith(RequestDispatcher) from server sends message to multiple browsers
jbrow May 1, 2012 3:09 PM (in response to cbrock)Thanks for the clarification.
Since Seam authenticates at the http session level, it would be useful to have a mode for the message bus that only broadcast within the session. In the interim, I guess I'll create topics that incorporate an ID that I generate for the session scope (injection of the Session or HttpSession seems to be broken in Seam -- even to the extent that you can't invoke the logout() method for Identity as it generates an exception).