3 Replies Latest reply on Aug 28, 2008 4:54 PM by Vladimir Kovalyuk

    Need explanation about Transactions on JavaBean

    alberto Gori Novice

      I am developing an application for plain Tomcat6.
      So no statefull or stateless session bean (my beans are only annotated by @Name).
      I am using JPA with Hibernate.

      Well, what is happening in my action methods about transactions?
      Do I need to annotated every controller class with @Transactional or not?

      Currenctly (without any @Transaction) if my save method performs 2 update, will they happens in 2 different transactions?

      If I add @Transactional, what happen if my method throws an Exception? Is it rollbacked?

      Thanks a lot.