SendAutoSms Connection TEST

This commit is contained in:
김현주
2025-07-09 16:04:54 +09:00
parent 940211f408
commit 0731deecf9
15 changed files with 331 additions and 13 deletions

View File

@@ -23,4 +23,25 @@ spring:
cache-duration: 10s
thymeleaf:
# 타임리프 템플릿 캐시 비활성화 (개발 환경에서는 false 로 설정 권장)
cache: false
cache: false
datasource:
kri:
driver-class-name: org.postgresql.Driver
jdbc-url: jdbc:postgresql://15.165.180.203:5432/korea_research
username: ko_research
password: koresearch1@#4
mms:
driver-class-name: org.postgresql.Driver
jdbc-url: jdbc:postgresql://15.165.180.203:5432/ko_research_hyunjoo
username: hyunjoo
password: hyunjoo1@#4
maximum-pool-size: 2
minimum-idle: 1
hikari:
maximum-pool-size: 10
minimum-idle: 5
idle-timeout: 120000
max-lifetime: 900000
connection-timeout: 5000
leak-detection-threshold: 30000

View File

@@ -101,6 +101,8 @@ logging:
# MyBatis 설정
# ==============================================
mybatis:
mapper-locations: classpath*:mappers/**/*Mapper.xml # 매퍼 파일 위치
mapper-locations:
kri: classpath*:mappers/**/*Mapper.xml # 매퍼 파일 위치
mms: classpath*:mappers/mms/*Mapper.xml # 매퍼 파일 위치
configuration:
log-impl: org.apache.ibatis.logging.stdout.StdOutImpl # SQL 로깅 구현체

View File

@@ -0,0 +1,32 @@
<?xml version="1.0" encoding="UTF-8" ?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd" >
<mapper namespace="app.module.mms.adapters.persistence.MMSMapper">
<insert id="createSmsAutoSend">
/* createSmsAutoSend : 문자 발송 insert */
INSERT INTO biz_msg
(
MSG_TYPE,
CMID,
REQUEST_TIME,
SEND_TIME,
DEST_PHONE,
SEND_PHONE,
MSG_BODY
)
VALUES
<foreach collection="sendHouseholds" item="item" separator=",">
(
5,
TO_CHAR(NOW(), 'YYYYMMDDHH24MISS') || '_' || #{item.householdNum},
NOW(),
NOW(),
#{item.phone},
#{sendPhone},
#{message}
)
</foreach>
</insert>
</mapper>