[jboss-dev-forums] [JBoss AS 7 Development] - Re: Readonly transactions in session beans
Lukasz Szymik
do-not-reply at jboss.com
Mon Jan 7 05:31:05 EST 2013
Lukasz Szymik [https://community.jboss.org/people/lszymik] created the discussion
"Re: Readonly transactions in session beans"
To view the discussion, visit: https://community.jboss.org/message/788709#788709
--------------------------------------------------------------
I read article about transaction pitfalls. It is very interesting. So far I know that JPA2 does not support it directly and Hibernate Session could be used directly. I have real life scenarion where it is lot of I18N messages stored in database and there is stateless session bean which is providing method: getMessage(int id). The getMessage method is annotated with TransactionAttribute(REQUIRED) so read is executed inside transaction. The messages are rarely changed so I started to look for optimalizations. Springs developers told me to use transaction - read only. However now I am little bit confused. Maybe removing transaction from getMessage method will be better solution.
Thanks for valueble information.
--------------------------------------------------------------
Reply to this message by going to Community
[https://community.jboss.org/message/788709#788709]
Start a new discussion in JBoss AS 7 Development at Community
[https://community.jboss.org/choose-container!input.jspa?contentType=1&containerType=14&container=2225]
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/jboss-dev-forums/attachments/20130107/c8fe62cb/attachment.html
More information about the jboss-dev-forums
mailing list