magicbacon
magicbacon

Reputation: 331

Spring Transaction Management in the Service Layer

I'm using tomcat and Spring 3.1 to develop a Maven webapp. The data source is defined as JNDI in tomcat. I'm thinking about using @Transactional annotation.

How to implement transaction in the service layer? Could you please point me at the right direction as what kind of transaction management should I use? JTA, JPA or others? And how to configure it? Which dependencies do I need?

Thanks.

Upvotes: 2

Views: 2111

Answers (1)

duffymo
duffymo

Reputation: 309008

You don't use JPA unless that's your implementation.

It's far more likely that you're using JTA.

Here is a Spring transactional tutorial.

Upvotes: 3

Related Questions