commit 4611271b5d822ce8fc5ac25794b637bd84a55a51 Author: mjkhan21 Date: Fri Apr 4 13:23:26 2025 +0900 최초 커밋 diff --git a/asset/image/sntris-layout.png b/asset/image/sntris-layout.png new file mode 100644 index 0000000..d02e6f2 Binary files /dev/null and b/asset/image/sntris-layout.png differ diff --git a/pom.xml b/pom.xml new file mode 100644 index 0000000..4ec7d1a --- /dev/null +++ b/pom.xml @@ -0,0 +1,113 @@ + + 4.0.0 + + + org.springframework.boot + spring-boot-starter-parent + 2.7.18 + + + + cokr.xit.interfaces + xit-sntris-interface + 0.0.1-SNAPSHOT + jar + + xit-sntris-interface + http://maven.apache.org + + + UTF-8 + + 17 + ${java.version} + ${java.version} + + + + + mvn2s + https://repo1.maven.org/maven2/ + + true + + + true + + + + egovframe + https://maven.egovframe.go.kr/maven/ + + true + + + false + + + + maven-public + https://nas.xit.co.kr:8888/repository/maven-public/ + + + + + + cokr.xit.boot + xit-foundation-starter + 23.04.01-SNAPSHOT + + + + cokr.xit.interfaces + xit-sntris + 23.04.01-SNAPSHOT + + + + + + xit-sntris-interface + + + + ${basedir}/src/main/resources + + intf-conf/*.* + spring/*.* + application.yml + + + + + + + org.apache.maven.plugins + maven-compiler-plugin + + + + com.github.therapi + therapi-runtime-javadoc-scribe + 0.15.0 + + + + + + org.springframework.boot + spring-boot-maven-plugin + + deploy + + + org.projectlombok + lombok + + + + + + + \ No newline at end of file diff --git a/release.xml b/release.xml new file mode 100644 index 0000000..2eb99e3 --- /dev/null +++ b/release.xml @@ -0,0 +1,19 @@ + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/java/cokr/xit/interfaces/sntris/SntrisInterfaceApplication.java b/src/main/java/cokr/xit/interfaces/sntris/SntrisInterfaceApplication.java new file mode 100644 index 0000000..fbbb326 --- /dev/null +++ b/src/main/java/cokr/xit/interfaces/sntris/SntrisInterfaceApplication.java @@ -0,0 +1,24 @@ +package cokr.xit.interfaces.sntris; + +import org.springframework.boot.SpringApplication; +import org.springframework.context.annotation.Bean; +import org.springframework.context.annotation.ImportResource; + +import cokr.xit.foundation.boot.FoundationApplication; +import io.swagger.v3.oas.models.OpenAPI; +import io.swagger.v3.oas.models.info.Info; + +@ImportResource("classpath:spring/context-*.xml") +public class SntrisInterfaceApplication extends FoundationApplication { + public static void main(String[] args) { + SpringApplication.run(SntrisInterfaceApplication.class, args); + } + + @Bean + public OpenAPI openAPI() { + return new OpenAPI() + .info(new Info() + .title("서울 세외수입 연계 시스템") + ); + } +} \ No newline at end of file diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml new file mode 100644 index 0000000..1ed195b --- /dev/null +++ b/src/main/resources/application.yml @@ -0,0 +1,53 @@ +server: + port: 18080 + servlet: + context-path: / + + ssl: + enabled: false + key-store: ssl/.keystore + key-store-type: PKCS12 + key-store-password: 5811807 + +spring: + application: + name: xit-sntris-interface + + main: + allow-bean-definition-overriding: true + sql: + init: + platform: mariadb 또는 oracle(해당 내용만 지정) + + datasource: + hikari: + driver-class-name: net.sf.log4jdbc.sql.jdbcapi.DriverSpy +# MariaDB + jdbc-url: jdbc:log4jdbc:mariadb://호스트:포트/DB이름?useUnicode=true&characterEncoding=utf8&serverTimezone=Asia/Seoul&useSSL=false&autocommit=false +# Oracle +# jdbc-url: jdbc:log4jdbc:oracle:thin:@호스트:포트:SID + username: 사용자 아이디 + password: 사용자 비밀번호 + auto-commit: false + + mvc: + static-path-pattern: /resources/**,/files/** + web: + resources: + static-locations: /resources/,file:files/ + +messageSource: + basenames: + - classpath:message/message-common + - classpath:org/egovframe/rte/fdl/property/messages/properties + +springdoc: + swagger-ui: + path: /swagger.html + +propertyService: + properties: + - tempDir: C:\temp + - pageUnit: 10 + - pageSize: 10 + - permitAccess: /intf/**/* diff --git a/src/main/resources/intf-conf/xit-sntris.conf b/src/main/resources/intf-conf/xit-sntris.conf new file mode 100644 index 0000000..c936db3 --- /dev/null +++ b/src/main/resources/intf-conf/xit-sntris.conf @@ -0,0 +1,21 @@ +{ + "host": "http://98.33.4.167:8082", +/* 운영: http://98.33.4.164 + 개발: http://98.33.4.167:8082 + */ + + "apis": [ + { /* 부과 */ + "name": "imposition", + "uri": "/BugaWebService/BugaWebService" + }, + { /* 사전통보 - 과태료 대장 등록 */ + "name": "prenotice", + "uri": "/SntrPreNoticeWebService/SntrPreNoticeWebService" + }, + { /* 사전통보 - 과태료 대장 조회 */ + "name": "fileoffer", + "uri": "/SntrFileOfferWebService/SntrFileOfferWebService" + } + ] +} \ No newline at end of file diff --git a/src/main/resources/log4jdbc.log4j2.properties b/src/main/resources/log4jdbc.log4j2.properties new file mode 100644 index 0000000..3b8ff2b --- /dev/null +++ b/src/main/resources/log4jdbc.log4j2.properties @@ -0,0 +1,4 @@ +log4jdbc.spylogdelegator.name=net.sf.log4jdbc.log.slf4j.Slf4jSpyLogDelegator + +log4jdbc.dump.sql.maxlinelength=0 +log4jdbc.drivers=org.mariadb.jdbc.Driver diff --git a/src/main/resources/logback-spring.xml b/src/main/resources/logback-spring.xml new file mode 100644 index 0000000..29f62ca --- /dev/null +++ b/src/main/resources/logback-spring.xml @@ -0,0 +1,82 @@ + + + + + + + + + + + + ${LOG_PATTERN} + + + + + ${LOG_PATH}/${LOG_FILE_NAME}.log + + ${LOG_PATTERN} + + + + + ${LOG_PATH}/${LOG_FILE_NAME}.%d{yyyy-MM-dd}_%i.log + + 10MB + + + 30 + + + + + + + error + ACCEPT + DENY + + + ${LOG_PATH}/${ERR_LOG_FILE_NAME}.log + + ${LOG_PATTERN} + + + + + ${LOG_PATH}/${ERR_LOG_FILE_NAME}.%d{yyyy-MM-dd}_%i.log + + + 10MB + + + 60 + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/main/resources/sql/mapper/base/test-mapper.xml b/src/main/resources/sql/mapper/base/test-mapper.xml new file mode 100644 index 0000000..d674130 --- /dev/null +++ b/src/main/resources/sql/mapper/base/test-mapper.xml @@ -0,0 +1,13 @@ + + + + +${sql} + +${sql} + +${sql} + +COMMIT + + \ No newline at end of file diff --git a/src/main/resources/sql/mapper/base/utility.xml b/src/main/resources/sql/mapper/base/utility.xml new file mode 100644 index 0000000..7f335db --- /dev/null +++ b/src/main/resources/sql/mapper/base/utility.xml @@ -0,0 +1,37 @@ + + + + + + +SELECT QROWS.* FROM ( + SELECT ROW_NUMBER() OVER() ROW_NUM + , COUNT(*) OVER() TOT_CNT, QBODY.* + FROM ( + + ) QBODY + ) QROWS +WHERE ROW_NUM BETWEEN ((#{pageNum} - 1) * #{fetchSize}) + 1 AND (#{pageNum} * #{fetchSize}) + + + +ORDER BY ${orderBy} + + + +DATE_FORMAT(CURRENT_TIMESTAMP, '%Y%m%d%H%i%s') +TO_CHAR(CURRENT_TIMESTAMP, 'YYYYMMDDHH24MISS') + +SELECTNOW FROM DUAL + +DATE_FORMAT(CURRENT_DATE, '%Y%m%d') +TO_CHAR(CURRENT_DATE, 'YYYYMMDD') + +SELECTTODAY FROM DUAL + +NVL(#{thisDay},) + +SELECTTHIS_DAY FROM DUAL + + \ No newline at end of file diff --git a/src/main/resources/sql/mybatis-config.xml b/src/main/resources/sql/mybatis-config.xml new file mode 100644 index 0000000..faa9415 --- /dev/null +++ b/src/main/resources/sql/mybatis-config.xml @@ -0,0 +1,21 @@ + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file