Thanks for your response, Simone. It is not clear if you meant I have to
rewrite my Jetty WebSockets-based application to a CometD based application
(that's a lot of work, and I am not sure we can do that), or if I can some
how add CometD for just the specific problem I am facing on my Jetty-based
WebSocket application. How do I integrate CometD into my Jetty WebSocket
based webapp? Are there examples out there?

Any help is appreciated.

Thanks!

On Mon, Apr 18, 2016 at 12:50 PM, Simone Bordet <[email protected]> wrote:

> Hi,
>
> On Mon, Apr 18, 2016 at 3:53 PM, Tickling Contest
> <[email protected]> wrote:
> > My scenario is a chat-room application that runs on Jetty WebSockets
> servers
> > fronted by HAProxy or some such load balancer.
> >
> > In a typical chat-room like application, when participants in a chat room
> > are load balanced across several servers, I am trying to understand how
> the
> > WebSockets application disseminates the chat message from one
> participant to
> > other chat room participants in the chat-room who may be connected to
> other
> > WebSocket servers in the cluster.
>
> Sure.
>
> > It appears like JDBC session-clustering,
> > for example, cannot work here as this does nothing for this WebSocket
> issue
> > (https://dev.eclipse.org/mhonarc/lists/jetty-users/msg03161.html),
> though it
> > appears like session clustering can help in getting the identity of the
> > server the other chat room participant is connected to currently.
>
> HTTP session clustering does not help you with WebSocket.
>
> > Is my understanding correct? If so, what solutions exist to solve the
> > WebSocket/chat-room problem I describe above?
>
> CometD (https://cometd.org).
>
> It's a sister project to Jetty, and provides all you need and more for
> distributed chats.
>
> Extended documentation: http://docs.cometd.org/
>
> Already existing distributed chat you can base on:
> https://github.com/sbordet/oort-chat-demo
>
> > My temporary solution was to
> > have each WS server that is load balanced by the HAProxy solution be
> > connected to the other WS servers in the cluster other via WebSocket (or
> > other technologies like RabbitMQ) and a simple messaging between them to
> > achieve the chat message dissemination I need in the chat room
> application.
>
> Already all figured out by CometD, and much more.
>
> --
> Simone Bordet
> ----
> http://cometd.org
> http://webtide.com
> Developer advice, training, services and support
> from the Jetty & CometD experts.
> _______________________________________________
> jetty-users mailing list
> [email protected]
> To change your delivery options, retrieve your password, or unsubscribe
> from this list, visit
> https://dev.eclipse.org/mailman/listinfo/jetty-users
>
_______________________________________________
jetty-users mailing list
[email protected]
To change your delivery options, retrieve your password, or unsubscribe from 
this list, visit
https://dev.eclipse.org/mailman/listinfo/jetty-users

Reply via email to