• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Tim Cooke
  • Liutauras Vilda
  • Jeanne Boyarsky
  • paul wheaton
Sheriffs:
  • Ron McLeod
  • Devaka Cooray
  • Henry Wong
Saloon Keepers:
  • Tim Holloway
  • Stephan van Hulst
  • Carey Brown
  • Tim Moores
  • Mikalai Zaikin
Bartenders:
  • Frits Walraven

EJB

 
Ranch Hand
Posts: 158
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
my reporting tool is for reporting services to over 10000 desktop users. There are
multiple regions and offices. Communication is via XML to desktop flash clients. Each
time a change in services is made by the help desk. The change is broadcasted to all
clients. Those which have a matching region path accept the data and dispaly it to the
user..

My concern is whether I should use session or entity ejbs. Each ejb reads data from the
db on initialization and creates an object for each office. When a change in services
occurs due to an update, the object is destroyed and a new one is created.

There is not going to be a class for each office
 
(instanceof Sidekick)
Posts: 8791
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I'd make a collection of POJOs. If you make them at startup and hold them in memory all day you need to think about a Singleton or static cache, right? Whether you use a session bean to build the cache and an entity bean to read them is really less important. I'm not terribly conversant with entity beans; if they really work better for you than that, let me know.

I'm interested in how you broadcast updates to 10,000 users. My project needs to broadcast to about 1200 using sockets. Say you connect to a server socket, send a message and disconnect in about a second. You're up to almost 3 hours to get the message out to everyone. And if any of the clients shut down you may have a long timeout before you discover they are gone. If you have a better way, please share!!

I'm also interested in how you keep these in-memory office objects in sync across a cluster. If one node updates an office, how do the others know about it?
[ October 12, 2005: Message edited by: Stan James ]
 
My name is Inigo Montoya, you killed my father, prepare to read a tiny ad:
Gift giving made easy with the permaculture playing cards
https://coderanch.com/t/777758/Gift-giving-easy-permaculture-playing
reply
    Bookmark Topic Watch Topic
  • New Topic