java - Can a WebLogic Singleton Service be used for wait/notify? -


we have app maintains hashmap in memory keyed specific user ids , had values representing system events. basic functionality user makes request web server checks hashmap events keyed id otherwise waits short amount of time on hashmap until either time out or notify executed on hashmap wakes client , processes event.

this working fine in single server environment moving clustered environment , unsure of best way handle particular piece.

thinking need utilize database queue these events , lose instant callback effect wait/notify unless possible somehow achieve using singelton service feature. using singleton service able wait on object 1 server , notified thread on other server in cluster?

i suggest use jms that. jms cluster-friendly , can configured persist events either in file storage or database. can select 2 models: queue or topic depending on how users need handled.


Comments

Popular posts from this blog

ios - UICollectionView Self Sizing Cells with Auto Layout -

node.js - ldapjs - write after end error -

DOM Manipulation in Wordpress (and elsewhere) using php -