[jboss-user] [EJB 3.0] - An global bean

aleksab do-not-reply at jboss.com
Wed Feb 14 07:45:18 EST 2007


I'm trying to figure out how to make a statefull bean that is global. I'll illustrate it with an example.

There a several clients that look up a bean, ie GlobalBean. Each client sends a string to the bean, which the GlobalBean stores. When a client asks the GlobalBean for the strings, all the strings are returned.

By implementing the GlobalBean as a stateful ejb bean, the GlobalBean just stores the string given by a specific client, since the bean is bound to the session between the bean and the client.

I want to create a bean which is not bound to the session in other words. I could do this by Message beans, but don't want to. I suppose I could do the same with an entity bean, but I don't want to involve databases.

So shouldn't it be some sort of annotatio like @MakePublicAvailable which exposes a bean for all sessions AND is stateful??

Ideas/suggestions are appreciated. 

View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4016341#4016341

Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4016341



More information about the jboss-user mailing list