[Design of EJB 3.0] - Re: ejb3 user transaction and serlvets
by adrian@jboss.org
"wolfc" wrote : The ejb3 logic shouldn't contain the determination whether this function is available or not.
| If we continue that logic than everybody who wants some service needs to have optional checks. Now we install 1 dummy service containing no logic.
| That's why I want the EJB3UserTransactionProvider depend on UserTransactionRegistry.
You're not listening. If you do that then its very hard to make the transactional
stuff optional or on-demand. Your way requires everything to be installed at
the start which isn't what we want further down the road for jboss5.
Things should only be created if they are actually needed/used.
e.g. No outbound connection factories means no CCM means no listeners on user transactions.
There should be no dummy/mock anything.
All if you to do is write:
if (blah != null)
like any normal programmer does around optional/configurable behaviour.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4193477#4193477
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4193477
16 years, 1 month
[Design of EJB 3.0] - Re: ejb3 user transaction and serlvets
by adrian@jboss.org
"wolfc" wrote : As for the 1st: I don't know.
Its the injection stuff. This is what I get
|
| @Resource
| private UserTransaction ut;
|
| System.out.println("@Resource=" + ut);
| System.out.println("java:/comp/UserTransaction=" + ctx.lookup("java:/comp/UserTransaction"));
| System.out.println("UserTransaction=" + ctx.lookup("UserTransaction"));
|
| 15:35:44,779 INFO [STDOUT] @Resource=org.jboss.ejb3.tx.UserTransactionImpl@a556cf
| 15:35:44,780 INFO [STDOUT] java:/comp/UserTransaction=org.jboss.tm.usertx.client.ServerVMClientUserTransaction@1b8b91f
| 15:35:44,780 INFO [STDOUT] UserTransaction=org.jboss.tm.usertx.client.ServerVMClientUserTransaction@1b8b91f
|
So the resource injection is not injecting java:comp/UserTransaction like it should
be doing.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=4193444#4193444
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=4193444
16 years, 1 month