[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread ALRubinger
On both accounts, the short answer is: that's entirely up to you. If both web modules, the application, and the MDB are deployed in the same JVM, that should make things easier for you; you'd be able to make a central registration point (probably backed by a Map so you can do key-based lookups)

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread ajay662
Thanks ALR. Couple of follow-up questions: Q1. How do I make 2 web modules share the stub for the SFSB? Q2. How do I access the same instance of SFSB (as used by web modules) from my MDBs? View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088188#4088188 Reply

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread ALRubinger
Why not use a Stateful bean; if you an build a mechanism such that the two web modules may share the stub (obtained from JNDI), then you can centralize all application-session data in there. Just make sure that only one request (Thread) is accessing the SFSB stub at any one time. I would thin

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread ajay662
Thanks. However I can not use DB. Idea is to ship these 3 modules to our customers, who will develop/package the final j2ee application. So the final j2ee application will have our modules as well as customer developed modules. This final application may or may not have DB and I don't want to m

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread waynebaylor
i would use a DB to store the data, even if it's not long lasting. i don't think it's a good idea to modify session data explicity--i would recommend the first web-module (W1) query for the current data. View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4088109#4

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-24 Thread ajay662
Yes. One web-module (W1) provides interface to client application and hence has knowledge of client sessions. Other web-module (W2) implements web-services and gets events/requests from a different source. W2 needs to modify session data which is inside W1. Also W2 posts JMS messages on a JMS t

[jboss-user] [EJB 3.0] - Re: sharing state between web modules and ejb modules

2007-09-23 Thread waynebaylor
do you mean share state for a given session? View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4087702#4087702 Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4087702 ___ jboss-user