oleksii-novikov-onix commented on code in PR #5858:
URL: https://github.com/apache/fineract/pull/5858#discussion_r3272188518


##########
fineract-cob/src/main/java/org/apache/fineract/cob/service/AbstractAccountLockService.java:
##########
@@ -59,8 +62,13 @@ public boolean isLockOverrulable(Long loanId) {
     @Transactional(propagation = Propagation.REQUIRES_NEW)
     public void updateCobAndRemoveLocks() {
         customLoanAccountLockRepository.updateLoanFromAccountLocks();
-        
loanAccountLockRepository.removeByLockOwnerInAndErrorIsNotNullAndLockPlacedOnCobBusinessDateIsNotNull(
-                List.of(LockOwner.LOAN_COB_CHUNK_PROCESSING, 
LockOwner.LOAN_INLINE_COB_PROCESSING));
+        
loanAccountLockRepository.removeByLockOwnerInAndErrorIsNotNullAndLockPlacedOnCobBusinessDateIsNotNull(COB_LOCK_OWNERS);
+    }
+
+    @Override
+    @Transactional(propagation = Propagation.REQUIRES_NEW)

Review Comment:
   Right, we do not need REQUIRES_NEW here. This method is invoked only from 
UnlockProcessedAccountsTasklet.execute().



##########
fineract-cob/src/main/java/org/apache/fineract/cob/service/AbstractAccountLockService.java:
##########
@@ -59,8 +62,13 @@ public boolean isLockOverrulable(Long loanId) {
     @Transactional(propagation = Propagation.REQUIRES_NEW)
     public void updateCobAndRemoveLocks() {
         customLoanAccountLockRepository.updateLoanFromAccountLocks();
-        
loanAccountLockRepository.removeByLockOwnerInAndErrorIsNotNullAndLockPlacedOnCobBusinessDateIsNotNull(
-                List.of(LockOwner.LOAN_COB_CHUNK_PROCESSING, 
LockOwner.LOAN_INLINE_COB_PROCESSING));
+        
loanAccountLockRepository.removeByLockOwnerInAndErrorIsNotNullAndLockPlacedOnCobBusinessDateIsNotNull(COB_LOCK_OWNERS);
+    }
+
+    @Override
+    @Transactional(propagation = Propagation.REQUIRES_NEW)

Review Comment:
   Removed



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to