충전이벤트가 적용되지 않는 버그 수정
This commit is contained in:
parent
72adae3f54
commit
3b9d8a4fcb
|
@ -4,6 +4,8 @@ import kr.co.vividnext.sodalive.member.Member
|
||||||
import org.springframework.context.event.EventListener
|
import org.springframework.context.event.EventListener
|
||||||
import org.springframework.scheduling.annotation.Async
|
import org.springframework.scheduling.annotation.Async
|
||||||
import org.springframework.stereotype.Component
|
import org.springframework.stereotype.Component
|
||||||
|
import org.springframework.transaction.annotation.Propagation
|
||||||
|
import org.springframework.transaction.annotation.Transactional
|
||||||
|
|
||||||
class ChargeSpringEvent(
|
class ChargeSpringEvent(
|
||||||
val chargeId: Long,
|
val chargeId: Long,
|
||||||
|
@ -16,6 +18,7 @@ class ChargeSpringEventListener(
|
||||||
) {
|
) {
|
||||||
@Async
|
@Async
|
||||||
@EventListener
|
@EventListener
|
||||||
|
@Transactional(propagation = Propagation.REQUIRES_NEW)
|
||||||
fun applyChargeEvent(event: ChargeSpringEvent) {
|
fun applyChargeEvent(event: ChargeSpringEvent) {
|
||||||
chargeEventService.applyChargeEvent(event.chargeId, event.member.id!!)
|
chargeEventService.applyChargeEvent(event.chargeId, event.member.id!!)
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue