From af9db38b88ba813e7c30649897246cc16166b945 Mon Sep 17 00:00:00 2001 From: leeheefull Date: Sun, 8 Dec 2024 11:41:30 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EA=B7=B8=EB=A3=B9=20=EC=83=9D=EC=84=B1?= =?UTF-8?q?=EC=8B=9C=20=EA=B7=B8=EB=A3=B9=20=EC=9C=A0=EC=A0=80=20=EB=AF=B8?= =?UTF-8?q?=EC=83=9D=EC=84=B1=20=EC=9D=B4=EC=8A=88=20=EC=88=98=EC=A0=95=20?= =?UTF-8?q?(#29)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/hero/alignlab/event/listener/GroupEventListener.kt | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/main/kotlin/com/hero/alignlab/event/listener/GroupEventListener.kt b/src/main/kotlin/com/hero/alignlab/event/listener/GroupEventListener.kt index 97b12e9..7ce83c5 100644 --- a/src/main/kotlin/com/hero/alignlab/event/listener/GroupEventListener.kt +++ b/src/main/kotlin/com/hero/alignlab/event/listener/GroupEventListener.kt @@ -3,6 +3,7 @@ package com.hero.alignlab.event.listener import com.hero.alignlab.domain.group.application.GroupUserService import com.hero.alignlab.event.model.CreateGroupEvent import io.github.oshai.kotlinlogging.KotlinLogging +import jakarta.transaction.Transactional import org.springframework.stereotype.Component import org.springframework.transaction.event.TransactionalEventListener @@ -12,6 +13,7 @@ class GroupEventListener( ) { private val logger = KotlinLogging.logger { } + @Transactional(value = Transactional.TxType.REQUIRES_NEW) @TransactionalEventListener fun handle(event: CreateGroupEvent) { groupUserService.saveSync(event.group.id, event.group.ownerUid)