From ca60c92bf24c8e5202045e88be15cfdf7af68174 Mon Sep 17 00:00:00 2001 From: "Jonguk. Lim" Date: Wed, 4 Sep 2024 13:47:08 +0900 Subject: [PATCH] =?UTF-8?q?fix:=20=EC=BD=94=EB=93=9C=20=EC=A0=95=EB=A6=AC?= =?UTF-8?q?=20=EB=B0=8F=20comment=20=EC=B6=94=EA=B0=80?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../entity/repository/BillRepository.java | 14 ++- .../IntgrnSendDetailRepository.java | 13 ++- .../repository/IntgrnSendMastRepository.java | 15 ++- .../intgrnnoti/service/IntgrnNotiService.java | 104 +++++++++--------- .../service/support/IntgrnNotiMaker.java | 18 +-- .../service/support/IntgrnNotiSender.java | 40 +++---- src/main/resources/config/conf-mybatis.yml | 9 +- 7 files changed, 121 insertions(+), 92 deletions(-) diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnbill/support/entity/repository/BillRepository.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnbill/support/entity/repository/BillRepository.java index 2bf57e6..0e879c4 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnbill/support/entity/repository/BillRepository.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnbill/support/entity/repository/BillRepository.java @@ -1,16 +1,22 @@ package cokr.xit.ens.modules.common.ctgy.intgrnbill.support.entity.repository; -import cokr.xit.ens.modules.common.ctgy.intgrnbill.support.entity.Bill; -import io.lettuce.core.dynamic.annotation.Param; +import java.util.Optional; + import org.springframework.data.jpa.repository.JpaRepository; import org.springframework.data.jpa.repository.Query; -import java.util.Optional; +import cokr.xit.ens.modules.common.ctgy.intgrnbill.support.entity.Bill; +import io.lettuce.core.dynamic.annotation.Param; + +/** + * Bill - ens_bill + * TODO: 생성 - Accept + */ public interface BillRepository extends JpaRepository { @Query("select a from Bill a inner join a.orgMng where a.billUid = :billUid") Optional findByBillUid(@Param("billUid") String billUid); -} \ No newline at end of file +} diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendDetailRepository.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendDetailRepository.java index 51ac691..206fc98 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendDetailRepository.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendDetailRepository.java @@ -1,12 +1,17 @@ package cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository; -import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendDetail; -import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendMast; -import org.springframework.data.jpa.repository.JpaRepository; - import java.util.List; import java.util.Optional; +import org.springframework.data.jpa.repository.JpaRepository; + +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendDetail; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendMast; + +/** + * Send details - ens_intgrn_snd_dtl + * TODO: 생성 - Accept + */ public interface IntgrnSendDetailRepository extends JpaRepository, IntgrnSendDetailRepositoryCustom { List findAllByIntgrnSendMast(IntgrnSendMast intgrnSendMast); diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendMastRepository.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendMastRepository.java index 177e915..0ee559f 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendMastRepository.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/domain/repository/IntgrnSendMastRepository.java @@ -1,13 +1,18 @@ package cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository; -import cokr.xit.ens.modules.common.code.StatCd; -import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendMast; -import cokr.xit.ens.modules.common.ctgy.intgrnnoti.code.TryStatCd; -import org.springframework.data.jpa.repository.JpaRepository; - import java.time.LocalDateTime; import java.util.List; +import org.springframework.data.jpa.repository.JpaRepository; + +import cokr.xit.ens.modules.common.code.StatCd; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.code.TryStatCd; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendMast; + +/** + * Send master - ens_intgrn_snd_dtl + * TODO: 생성 - Accept + */ public interface IntgrnSendMastRepository extends JpaRepository, IntgrnSendMastRepositoryCustom { List findAllByIntSendMastIdIn(List sendMastIds); diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/IntgrnNotiService.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/IntgrnNotiService.java index 4f599ba..668fd31 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/IntgrnNotiService.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/IntgrnNotiService.java @@ -1,5 +1,16 @@ package cokr.xit.ens.modules.common.ctgy.intgrnnoti.service; +import java.time.LocalDateTime; +import java.util.Arrays; +import java.util.Collections; +import java.util.List; +import java.util.stream.Collectors; +import java.util.stream.Stream; + +import org.springframework.stereotype.Service; +import org.springframework.transaction.annotation.Propagation; +import org.springframework.transaction.annotation.Transactional; + import cokr.xit.ens.core.aop.EnsResponseVO; import cokr.xit.ens.core.exception.EnsException; import cokr.xit.ens.core.exception.code.EnsErrCd; @@ -9,18 +20,16 @@ import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.IntgrnSendMast; import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository.IntgrnSendDetailRepository; import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository.IntgrnSendMastRepository; import cokr.xit.ens.modules.common.ctgy.intgrnnoti.model.IntgrnNotiAcceptReqDTO; -import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.*; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.IntgrnNotiAcceptor; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.IntgrnNotiMaker; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.IntgrnNotiRsltFetcher; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.IntgrnNotiRsltProvider; +import cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support.IntgrnNotiSender; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.springframework.stereotype.Service; -import org.springframework.transaction.annotation.Propagation; -import org.springframework.transaction.annotation.Transactional; - -import java.time.LocalDateTime; -import java.util.Arrays; -import java.util.List; -import java.util.stream.Collectors; +import lombok.val; +// TODO: 전자고지 서비스 @Slf4j @Service @RequiredArgsConstructor @@ -32,7 +41,7 @@ public class IntgrnNotiService { private final IntgrnNotiAcceptor intgrnSendAcceptor; private final IntgrnNotiMaker intgrnNotiMaker; - + private final IntgrnNotiSender intgrnNotiSender; private final IntgrnNotiRsltFetcher intgrnNotiRsltFetcher; private final IntgrnNotiRsltProvider intgrnNotiRsltProvider; @@ -44,8 +53,8 @@ public class IntgrnNotiService { * @return */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO accept(IntgrnNotiAcceptReqDTO reqDTO) { - EnsResponseVO responseVO = null; + public EnsResponseVO accept(IntgrnNotiAcceptReqDTO reqDTO) { + EnsResponseVO responseVO = null; try { responseVO = intgrnSendAcceptor.statBegin(reqDTO); if (!EnsErrCd.OK.equals(responseVO.getErrCode())) @@ -70,7 +79,7 @@ public class IntgrnNotiService { * @return */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO remake(Long intSendMastId) { + public EnsResponseVO remake(Long intSendMastId) { try { IntgrnSendMast sendMast = intgrnSendMastRepository.findById(intSendMastId) .orElseThrow(() -> new EnsException(EnsErrCd.MAKE404, "일치하는 자료가 없습니다.")); @@ -84,7 +93,7 @@ public class IntgrnNotiService { .build(); } - intgrnNotiMaker.statReady(Arrays.asList(intSendMastId)); + intgrnNotiMaker.statReady(Collections.singletonList(intSendMastId)); return this.make(intSendMastId); @@ -96,12 +105,12 @@ public class IntgrnNotiService { * @return */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO makeAll() { + public EnsResponseVO makeAll() { List sendMastIds = intgrnSendMastRepository.findAllByStatCdIn(Arrays.asList(StatCd.accept)) .stream() .map(row -> row.getIntSendMastId()) .collect(Collectors.toList()); - if (sendMastIds.size() < 1) + if (sendMastIds.isEmpty()) return EnsResponseVO.errBuilder() .errCode(EnsErrCd.MAKE404) .errMsg("\"접수(accept)\" 상태인 자료가 없습니다") @@ -109,24 +118,24 @@ public class IntgrnNotiService { intgrnNotiMaker.statReady(sendMastIds); - List resultInfo = sendMastIds.stream() - .map(intSendMastId -> this.make(intSendMastId)) - .collect(Collectors.toList()); + val resultInfo = sendMastIds.stream() + .map(this::make) + .collect(Collectors.toList()); return EnsResponseVO.okBuilder().resultInfo(resultInfo).build(); } - private EnsResponseVO make(Long intSendMastId) { - EnsResponseVO responseVO = intgrnNotiMaker.statBegin(intSendMastId); + private EnsResponseVO make(Long intSendMastId) { + EnsResponseVO responseVO = intgrnNotiMaker.statBegin(intSendMastId); if (!EnsErrCd.OK.equals(responseVO.getErrCode())) return responseVO; try { -// +// // responseVO = this.makeBillLink(intSendMastId); // if (!EnsErrCd.OK.equals(responseVO.getErrCode())) // throw new EnsException(responseVO.getErrCode(), responseVO.getErrMsg()); - + responseVO = intgrnNotiMaker.execute(intSendMastId); if (!EnsErrCd.OK.equals(responseVO.getErrCode())) throw new EnsException(responseVO.getErrCode(), responseVO.getErrMsg()); @@ -159,10 +168,10 @@ public class IntgrnNotiService { * @return */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO sendBulk(Long intSendMastId) { + public EnsResponseVO sendBulk(Long intSendMastId) { try { - if (intgrnSendDetailRepository.findAllBySendTargetAndSendMast(IntgrnSendMast.builder().intSendMastId(intSendMastId).build()).size() < 1) + if (intgrnSendDetailRepository.findAllBySendTargetAndSendMast(IntgrnSendMast.builder().intSendMastId(intSendMastId).build()).isEmpty()) throw new EnsException(EnsErrCd.SEND404, "일치하는 자료가 없거나 전송 가능한 상태의 자료가 없습니다. (1회차:상태=makeok&try상태=stby&dtl상태=MAKING, 2~3회차:try상태:ok/fail&발송일시=기한경과&dtl상태=실패(ACPT_FAIL/FAIL/...)"); } catch (EnsException e) { return EnsResponseVO.errBuilder() @@ -171,7 +180,7 @@ public class IntgrnNotiService { .build(); } - List sendMastIds = Arrays.asList(intSendMastId); + List sendMastIds = Collections.singletonList(intSendMastId); return this.send(sendMastIds); @@ -181,10 +190,10 @@ public class IntgrnNotiService { * (대량)전송 서비스-일괄 */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO sendBulkAll() { + public EnsResponseVO sendBulkAll() { List intSendMastIds = intgrnSendDetailRepository.findIntSendMastIdsBySendTarget(); - if (intSendMastIds.size() < 1) + if (intSendMastIds.isEmpty()) return EnsResponseVO.errBuilder() .errCode(EnsErrCd.SEND404) .errMsg("전송 타깃 데이터가 없습니다.") @@ -193,14 +202,11 @@ public class IntgrnNotiService { return this.send(intSendMastIds); } - private EnsResponseVO send(List intSendMastIds) { - List resultInfo = intSendMastIds.stream() - .map(intSendMastId -> { - intgrnNotiSender.statBegin(intSendMastId); - return intSendMastId; - }) - .map(intSendMastId -> intgrnNotiSender.execute(intSendMastId)) - .collect(Collectors.toList()); + private EnsResponseVO send(List intSendMastIds) { + val resultInfo = intSendMastIds.stream() + .peek(intgrnNotiSender::statBegin) + .map(intgrnNotiSender::execute) + .collect(Collectors.toList()); return EnsResponseVO.okBuilder().resultInfo(resultInfo).build(); @@ -211,18 +217,18 @@ public class IntgrnNotiService { * 전송(성공/실패) 결과 가져오기 */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO statBulk(Long intSendMastId) { + public EnsResponseVO statBulk(Long intSendMastId) { IntgrnSendMast intgrnSendMast = null; try { intgrnSendMast = intgrnSendMastRepository.findById(intSendMastId) .orElseThrow(() -> new EnsException(EnsErrCd.ERR404, String.format("[ intSendMastId %s ]와 일치하는 자료가 없습니다.", intSendMastId))); int validCnt = 0; IntgrnSendMast finalIntgrnSendMast = intgrnSendMast; - if (!Arrays.asList(StatCd.sendok, StatCd.sendcmplt, StatCd.open).stream() - .anyMatch(statCd -> statCd.equals(finalIntgrnSendMast.getStatCd()))) + if (Stream.of(StatCd.sendok, StatCd.sendcmplt, StatCd.open) + .noneMatch(statCd -> statCd.equals(finalIntgrnSendMast.getStatCd()))) validCnt++; - if (!Arrays.asList(TryStatCd.sndRsrv, TryStatCd.sndRtme).stream() - .anyMatch(statCd -> statCd.equals(finalIntgrnSendMast.getTryStatCd()))) + if (Stream.of(TryStatCd.sndRsrv, TryStatCd.sndRtme) + .noneMatch(statCd -> statCd.equals(finalIntgrnSendMast.getTryStatCd()))) validCnt++; if (validCnt == 2) throw new EnsException(EnsErrCd.RSLT404, "\"진행상태\"가 전송성공/전송완료/열람중(sendok/sendcmplt/open) 또는 \"현재 회차상태\"가 예약전송/실시간전송(sndRsrv/sndRtme) 상태가 아닙니다."); @@ -233,17 +239,17 @@ public class IntgrnNotiService { .build(); } - return this.stat(Arrays.asList(intgrnSendMast)); + return this.stat(Collections.singletonList(intgrnSendMast)); } /** * 전송(성공/실패) 결과 모두 가져오기 */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO statBulkAll() { + public EnsResponseVO statBulkAll() { // List intgrnSendMasts = intgrnSendMastRepository.findAllByStatCdIn(Arrays.asList(StatCd.sendok, StatCd.sendcmplt, StatCd.open)); List intgrnSendMasts = intgrnSendMastRepository.findAllByStatCdInOrTryStatCdIn(Arrays.asList(StatCd.sendok, StatCd.sendcmplt, StatCd.open), Arrays.asList(TryStatCd.sndRsrv, TryStatCd.sndRtme)); - if (intgrnSendMasts.size() < 1) + if (intgrnSendMasts.isEmpty()) return EnsResponseVO.errBuilder() .errCode(EnsErrCd.RSLT404) // .errMsg("\"전송성공/전송완료/열람중(sendok/sendcmplt/open)\" 상태인 자료가 없습니다") @@ -253,10 +259,10 @@ public class IntgrnNotiService { return this.stat(intgrnSendMasts); } - private EnsResponseVO stat(List intgrnSendMasts) { - List resultInfo = intgrnSendMasts.stream() - .map(data -> intgrnNotiRsltFetcher.execute(data.getIntSendMastId())) - .collect(Collectors.toList()); + private EnsResponseVO stat(List intgrnSendMasts) { + val resultInfo = intgrnSendMasts.stream() + .map(data -> intgrnNotiRsltFetcher.execute(data.getIntSendMastId())) + .collect(Collectors.toList()); return EnsResponseVO.okBuilder().resultInfo(resultInfo).build(); } @@ -268,7 +274,7 @@ public class IntgrnNotiService { * @return */ @Transactional(propagation = Propagation.SUPPORTS) - public EnsResponseVO sendResultProvide(Long intSendMastId) { + public EnsResponseVO sendResultProvide(Long intSendMastId) { return intgrnNotiRsltProvider.execute(intSendMastId); } diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiMaker.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiMaker.java index c04d95b..9c8535d 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiMaker.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiMaker.java @@ -1,5 +1,14 @@ package cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support; +import java.util.List; +import java.util.Optional; +import java.util.stream.Collectors; + +import org.springframework.context.ApplicationEventPublisher; +import org.springframework.stereotype.Component; +import org.springframework.transaction.annotation.Propagation; +import org.springframework.transaction.annotation.Transactional; + import cokr.xit.ens.core.aop.EnsResponseVO; import cokr.xit.ens.core.exception.EnsException; import cokr.xit.ens.core.exception.code.EnsErrCd; @@ -20,15 +29,8 @@ import cokr.xit.ens.modules.common.domain.support.FieldError; import cokr.xit.ens.modules.common.monitor.MessageByPhase; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.springframework.context.ApplicationEventPublisher; -import org.springframework.stereotype.Component; -import org.springframework.transaction.annotation.Propagation; -import org.springframework.transaction.annotation.Transactional; - -import java.util.List; -import java.util.Optional; -import java.util.stream.Collectors; +// TODO: Make @Slf4j @Component @RequiredArgsConstructor diff --git a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiSender.java b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiSender.java index f721d0f..40b4b4b 100644 --- a/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiSender.java +++ b/src/main/java/cokr/xit/ens/modules/common/ctgy/intgrnnoti/service/support/IntgrnNotiSender.java @@ -1,5 +1,13 @@ package cokr.xit.ens.modules.common.ctgy.intgrnnoti.service.support; +import java.util.Arrays; +import java.util.List; + +import org.springframework.context.ApplicationEventPublisher; +import org.springframework.stereotype.Component; +import org.springframework.transaction.annotation.Propagation; +import org.springframework.transaction.annotation.Transactional; + import cokr.xit.ens.core.aop.EnsResponseVO; import cokr.xit.ens.core.exception.EnsException; import cokr.xit.ens.core.exception.code.EnsErrCd; @@ -13,14 +21,8 @@ import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository.IntgrnSendD import cokr.xit.ens.modules.common.ctgy.intgrnnoti.domain.repository.IntgrnSendMastRepository; import lombok.RequiredArgsConstructor; import lombok.extern.slf4j.Slf4j; -import org.springframework.context.ApplicationEventPublisher; -import org.springframework.stereotype.Component; -import org.springframework.transaction.annotation.Propagation; -import org.springframework.transaction.annotation.Transactional; - -import java.util.Arrays; -import java.util.List; +// TODO: Send @Slf4j @Component @RequiredArgsConstructor @@ -49,13 +51,13 @@ public class IntgrnNotiSender extends SendProcTemplate { IntgrnSendMast sendMast = intgrnSendMastRepository.findById(intSendMastId).orElseThrow(() -> new EnsException(EnsErrCd.SEND404, String.format("일치하는 발송마스터 자료가 없습니다. [ intSendMastId %s ]", intSendMastId))); sendMast.setTryStatCd(TryStatCd.start); - + respVO = EnsResponseVO.okBuilder().resultInfo(intSendMastId).build(); } catch (EnsException e) { - + respVO = EnsResponseVO.errBuilder().errCode(e.getErrCd()).errMsg(e.getMessage()).build(); } catch (Exception e) { - + respVO = EnsResponseVO.errBuilder().errCode(EnsErrCd.SEND500).errMsg(e.getMessage()).build(); } @@ -76,37 +78,37 @@ public class IntgrnNotiSender extends SendProcTemplate { intgrnSendMast = intgrnSendMastRepository.findById(intSendMastId).orElseThrow(() -> new EnsException(EnsErrCd.SEND404, String.format("일치하는 발송마스터 자료가 없습니다. [ intSendMastId %s ]", intSendMastId))); intgrnSendDetails = intgrnSendDetailRepository.findAllBySendTargetAndSendMastAndTryStatCdIn(intgrnSendMast, Arrays.asList(TryStatCd.start)); - if (intgrnSendDetails.size() < 1) + if (intgrnSendDetails.isEmpty()) throw new EnsException(EnsErrCd.SEND500, "조회된 발송상세 자료가 없음."); PostSeCd postSeCd = null; final int currentTryNum = intgrnSendMast.getTrySeq() + 1; - final boolean isReserve = currentTryNum == 1 ? true : false; + final boolean isReserve = currentTryNum == 1; final TryStatCd tryStatCd = currentTryNum == 1 ? TryStatCd.sndRsrv : TryStatCd.sndRtme; if (currentTryNum == 1) postSeCd = intgrnSendMast.getTry1(); else if (currentTryNum == 2) postSeCd = intgrnSendMast.getTry2(); else if (currentTryNum == 3) postSeCd = intgrnSendMast.getTry3(); - AcceptDataFactory makerFactory = new AcceptDataMakerFactory(intgrnSendMast, intgrnSendDetails, isReserve); - + AcceptDataFactory> makerFactory = new AcceptDataMakerFactory(intgrnSendMast, intgrnSendDetails, isReserve); + applicationEventPublisher.publishEvent(makerFactory.get(postSeCd)); - + intgrnSendMast.setTrySeq(currentTryNum); intgrnSendMast.setTryStatCd(tryStatCd); - + PostSeCd finalPostSeCd = postSeCd; intgrnSendDetails.forEach(data -> data.setCurPostSe(finalPostSeCd)); - + respVO = EnsResponseVO.okBuilder().build(); } catch (EnsException e) { - + respVO = EnsResponseVO.errBuilder().errCode(e.getErrCd()).errMsg(e.getMessage()).build(); } catch (Exception e) { - + respVO = EnsResponseVO.errBuilder().errCode(EnsErrCd.SEND500).errMsg(e.getMessage()).build(); } diff --git a/src/main/resources/config/conf-mybatis.yml b/src/main/resources/config/conf-mybatis.yml index a341feb..268c619 100644 --- a/src/main/resources/config/conf-mybatis.yml +++ b/src/main/resources/config/conf-mybatis.yml @@ -1,4 +1,7 @@ mybatis: - mapper-locations: mybatis-mapper/**/*.xml - configuration: - map-underscore-to-camel-case: true \ No newline at end of file + config-location: classpath:mybatis-mapper/mybatis-config.xml + mapper-locations: + - classpath:mybatis-mapper/**/*Mapper.xml + - classpath:mybatis-mapper/**/*-mapper.xml +# configuration: +# map-underscore-to-camel-case: true