Top "Spring-transactions" questions

Questions related to Spring's Transaction API (programmatic or declarative)

Spring transaction REQUIRED vs REQUIRES_NEW : Rollback Transaction

I have a method that has the propagation = Propagation.REQUIRES_NEW transactional property: @Transactional(propagation = Propagation.REQUIRES_NEW) public void …

java spring hibernate transactions spring-transactions
The matching wildcard is strict, but no declaration can be found for element 'tx:annotation-driven'

I am trying to configure JSF+Spring+hibernate and I'm tying to run a test but when I use this "…

spring transactions spring-transactions
How to manually force a commit in a @Transactional method?

I'm using Spring / Spring-data-JPA and find myself needing to manually force a commit in a unit test. My use case …

java spring jpa spring-data spring-transactions
@Transactional method calling another method without @Transactional anotation?

I've seen a method in a Service class that was marked as @Transactional, but it was also calling some other …

java spring spring-transactions transactional
Spring - Is it possible to use multiple transaction managers in the same application?

I'm new to Spring and I'm wondering if its possible to use numerous transaction managers in the same application? I …

java spring jpa spring-transactions transactionmanager
Spring @Transactional not working

I previously had a post on this issue that was resolved. However since rebuilding the project with auto wired beans …

spring spring-mvc spring-transactions transactional
Hibernate transaction manager configurations in Spring

In my project I use Hibernate with programmatic transaction demarcation. Every time in my Service methods i write something similar …

java hibernate spring spring-transactions
What is the difference between defining @Transactional on class vs method

Case1 @Transactional public class UserServiceImpl implements UserService { ................... public void method1(){ try{ method2(); }catch(Exception e){ } } public void method2(){ } } Case2 public …

java spring spring-mvc spring-transactions
Hibernate: LazyInitializationException: failed to lazily initialize a collection of role. Could not initialize proxy - no Session

I have next error: nested exception is org.hibernate.LazyInitializationException: failed to lazily initialize a collection of role: com.example.…

java spring hibernate jpa spring-transactions
Spring JTA configuration - how to set TransactionManager?

We configure our Spring transaction in Spring config as: <tx:jta-transaction-manager/> I gather this means that Spring will …

java spring jboss jta spring-transactions