TransactionalEventListener -> EventListener 변경
This commit is contained in:
parent
11f1f781a0
commit
b331e6e152
|
@ -2,8 +2,9 @@ package kr.co.vividnext.sodalive.fcm
|
||||||
|
|
||||||
import kr.co.vividnext.sodalive.member.MemberRepository
|
import kr.co.vividnext.sodalive.member.MemberRepository
|
||||||
import org.slf4j.LoggerFactory
|
import org.slf4j.LoggerFactory
|
||||||
|
import org.springframework.context.event.EventListener
|
||||||
|
import org.springframework.scheduling.annotation.Async
|
||||||
import org.springframework.stereotype.Component
|
import org.springframework.stereotype.Component
|
||||||
import org.springframework.transaction.event.TransactionalEventListener
|
|
||||||
|
|
||||||
enum class FcmEventType {
|
enum class FcmEventType {
|
||||||
ALL, INDIVIDUAL, CREATE_LIVE, START_LIVE, UPLOAD_CONTENT, SEND_MESSAGE
|
ALL, INDIVIDUAL, CREATE_LIVE, START_LIVE, UPLOAD_CONTENT, SEND_MESSAGE
|
||||||
|
@ -29,7 +30,8 @@ class FcmSendListener(
|
||||||
) {
|
) {
|
||||||
private val logger = LoggerFactory.getLogger(FcmSendListener::class.java)
|
private val logger = LoggerFactory.getLogger(FcmSendListener::class.java)
|
||||||
|
|
||||||
@TransactionalEventListener
|
@Async
|
||||||
|
@EventListener
|
||||||
fun send(fcmEvent: FcmEvent) {
|
fun send(fcmEvent: FcmEvent) {
|
||||||
when (fcmEvent.type) {
|
when (fcmEvent.type) {
|
||||||
FcmEventType.ALL -> {
|
FcmEventType.ALL -> {
|
||||||
|
|
Loading…
Reference in New Issue