Realtime messaging in portal client

Hi,

I would like to implement a chat service in the portal client module. The portal client is an Angularjs SPA, which is communicating with the Cuba App over the REST API.

Can I use the already built in Atmosphere framework to implement a parallel messaging channel?
I hope yes, if so is there any integration help or guideline where and how I can start?

In a very simple version i would like to implement the following scenario.

  1. UserA query a presence service over the REST API to see if UserB is online.
  2. If UserB is Online the UserA send to him a private message with REST API call, so here I am not using socket.io
  3. Because UserB is online and logged in the chat service, I notify him with Atmosphere about the new chat message.
    4.UserB browser using the Atmosphere client library receiving the message and displaying it, and sending acknowledge over REST API or Atmosphere.
  4. If UserB is offline, i simply storing the message,and when he logs in he will receive all pending message with REST API call.

Can it be implemented in this way?
Regards

Hi,

CUBA portal does not have any integrations with WebSocket/PUSH technologies and Atmosphere is only used for web client with Vaadin. You can integrate any third-party library on your own to implement real-time messaging in your portal.

For now we do not plan to integrate Atmosphere Framework to the portal module.

1 Like