You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@inlong.apache.org by do...@apache.org on 2022/03/25 10:10:50 UTC

[incubator-inlong] branch master updated: [INLONG-3362][Manager] Make Group.updateStatus new Transaction (#3364)

This is an automated email from the ASF dual-hosted git repository.

dockerzhang pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/incubator-inlong.git


The following commit(s) were added to refs/heads/master by this push:
     new 5a0ea5c  [INLONG-3362][Manager] Make Group.updateStatus new Transaction (#3364)
5a0ea5c is described below

commit 5a0ea5c5ac30c4b04deb7fa73dc2b4dbe55a9e39
Author: kipshi <48...@users.noreply.github.com>
AuthorDate: Fri Mar 25 18:10:46 2022 +0800

    [INLONG-3362][Manager] Make Group.updateStatus new Transaction (#3364)
---
 .../inlong/manager/service/core/impl/InlongGroupServiceImpl.java      | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/InlongGroupServiceImpl.java b/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/InlongGroupServiceImpl.java
index bbf7eeb..c5516ed 100644
--- a/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/InlongGroupServiceImpl.java
+++ b/inlong-manager/manager-service/src/main/java/org/apache/inlong/manager/service/core/impl/InlongGroupServiceImpl.java
@@ -53,6 +53,7 @@ import org.slf4j.LoggerFactory;
 import org.springframework.beans.factory.annotation.Autowired;
 import org.springframework.stereotype.Service;
 import org.springframework.transaction.annotation.Isolation;
+import org.springframework.transaction.annotation.Propagation;
 import org.springframework.transaction.annotation.Transactional;
 
 import java.util.Arrays;
@@ -290,7 +291,8 @@ public class InlongGroupServiceImpl implements InlongGroupService {
     }
 
     @Override
-    @Transactional(rollbackFor = Throwable.class, isolation = Isolation.REPEATABLE_READ)
+    @Transactional(rollbackFor = Throwable.class, isolation = Isolation.REPEATABLE_READ,
+            propagation = Propagation.REQUIRES_NEW)
     public boolean updateStatus(String groupId, Integer status, String operator) {
         LOGGER.info("begin to update group status to [{}] by groupId={}, username={}", status, groupId, operator);
         Preconditions.checkNotNull(groupId, Constant.GROUP_ID_IS_EMPTY);