question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

Lightmin brakes the transaction handling of spring data jpa repositories

See original GitHub issue

Lightmin brakes the transaction handling of spring data jpa repositories. Per default spring data jpa repositories can be used directly and each method execution is wrapped with a correct transaction. As soon as one enabels Spring Batch Lightmin, the repository methods are not executed in a transaction anymore - or at least nothing is commited anymore.

Please see this example project: https://github.com/imod/lightmin-transaction - it contains a simple demo application which inserts some records to the database at startup (in com.example.demo.LightminTransactionApplication.demo(...). The testcase fails as long as @EnableLightminEmbedded and @EnableLightminJdbcConfigurationRepository are enabled. as soon as these two annotations are commented/removed, the test case works find.

Issue Analytics

  • State:closed
  • Created 3 years ago
  • Comments:7 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
tuxdevelopcommented, Jan 12, 2021

Hi @imod, I will have a detailed look into this via #55

Read more comments on GitHub >

github_iconTop Results From Across the Web

Managing Transactions with Spring and Spring Data JPA
Spring's @Transactional annotation provides an easy way to declare your transaction handling. Here is how it works and what the different attributes do....
Read more >
Transactions with Spring and JPA - Baeldung
A quick, practical tutorial on how to configure a separate data source for testing in a Spring application. Read more →. Quick Guide...
Read more >
JPA Repository unnecessarily requires transactions #2226
I've had a look at what happens within Spring Framework in combination with the EntityManager using SUPPORTS propagation mode. As part of the...
Read more >
Spring Data JPA fails to invoke JtaTransactionManager
In a nutshell - it would seem that SDJ simply fails to invoke an implementation of Spring's PlatformTransactionManager once there is any kind...
Read more >
2. JPA Repositories - Spring
2.1.2 Annotation based configuration. The Spring Data JPA repositories support cannot only be activated through an XML namespace but also using an annotation ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found