Parcourir la source

remove jdbcTemplate in ThreadLocal after fetching it

sunyj il y a 7 ans
Parent
commit
4057fbaebe
1 fichiers modifiés avec 1 ajouts et 0 suppressions
  1. 1 0
      src/main/java/com/uas/ps/product/sync/WaitSyncHelper.java

+ 1 - 0
src/main/java/com/uas/ps/product/sync/WaitSyncHelper.java

@@ -85,6 +85,7 @@ public class WaitSyncHelper {
             batchSize = syncRepository.getBatchSize();
             syncRepository.unsetSessionVariable();
         } else {
+            jdbcTemplates.remove();
             batchSize = jdbcTemplate.execute(new CallableStatementCreator() {
                 @Override
                 public CallableStatement createCallableStatement(Connection connection) throws SQLException {