-
Notifications
You must be signed in to change notification settings - Fork 9
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Pessimistic Read lock scenarios (#1123)
* ChennuruAkhil#8 Added test case for pessimistic read lock scenario * ChennuruAkhil#8 Added update scenario during pessimistic read lock * Fixed Sonar issues * Fixed codacy checks
- Loading branch information
1 parent
3390b0f
commit f09b6ad
Showing
5 changed files
with
69 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
3 changes: 2 additions & 1 deletion
3
...oot-jpa-locks/src/main/java/com/example/locks/repositories/CustomizedActorRepository.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,12 +1,13 @@ | ||
package com.example.locks.repositories; | ||
|
||
import com.example.locks.entities.Actor; | ||
import jakarta.persistence.LockModeType; | ||
|
||
public interface CustomizedActorRepository { | ||
|
||
long getLockTimeout(); | ||
|
||
void setLockTimeout(long timeoutDurationInMs); | ||
|
||
Actor getActorAndObtainPessimisticWriteLockingOnItById(Long id); | ||
Actor getActorAndObtainPessimisticLockingOnItById(Long id, LockModeType lockModeType); | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters