Easy task for GAE app coders.
I need a Google app that implements implements a publish-subscribe messaging framework in Java.
This should be achievable more or less as follows....
1) the publisher opens a session, a session Id is sent to the client
2) the publisher sends variable sized chunks of binary/text data to the session
3) if session has subscribers, the received chunks of data are stored with a timestamp and the session Id
4) send fail/success message to publisher
5) repeat from 2 until publisher closes session (by sending a specific message etc.)
6) clear session data
1) subscriber subscribes to a session by providing a session id
2) the subscriber polls the server (every X amount of seconds), and
the server replies with all chunks of data for the session not yet retrieved by the client
3) if all subscribers for the session have received all data chunks before time Y, clean up all data chunks with a timestamp less than Y
4) repeat from 2 until subscriber closes session (by sending a specific message etc.)
5) clear subscription related data
IMPORTANT: all the above must be performed withing GAE limitations (including execution preemption) and as efficiently as possible. All communication between publisher/subscriber and the server is over HTTP.
NOTE: Maybe this can be implemented using Channel API for Google App Engine. However note that the publisher/subscriber clients will be applications, not web pages.
Feel free to contact me with any suggestions or clarification queries.