airavata-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jeffery Kinnison <Jeffery.D.Kinniso...@nd.edu>
Subject WebSockets for Real-Time PGA Updates
Date Thu, 16 Jun 2016 15:09:56 GMT
Hi all,

As part of my GSoC Project, I'm trying to integrate WebSockets into the PGA
(initially just to stream application status and results, but eventually to
handle other other tasks as well). I wanted to run tsome integration ideas
by the dev list to get some feedback. These are all ideas for the back-end,
as any client-side WebSockets usage will have to use the browser WebSockets
API.

   1. Write messages from applications to the MySQL database and
   periodically poll that table for changes; any changes are routed to the
   correct user over a WebSockets connection. In this scenario, each instance
   of a running application would get its own row in a table (say,
   APPLICATION_RUNTIME_DATA), and this row would be updated with JSON from the
   running application. Polling the database for changes could get costly,
   though.
   2. Using the database setup described above, all updates to MySQL could
   be routed through RabbitMQ, Redis or some similar messaging or pub/sub
   setup. Then, a subscriber could write the changes to MySQL and send the
   update to the appropriate client over a WebSockets connection. In this
   scenario, database reads only happen when a client first connects to the
   WebSockets server, to retrieve existing information.

Thoughts?

Jeff K.

Mime
View raw message