From e9ac6b20bb3515fd0f68054031039148cec1801e Mon Sep 17 00:00:00 2001 From: "semin.baek" Date: Fri, 27 Jun 2025 16:12:39 +0900 Subject: [PATCH] =?UTF-8?q?=EB=A9=94=EC=8B=9C=EC=A7=80=20=EB=B6=84?= =?UTF-8?q?=EC=84=9D=20=EA=B8=B0=EB=8A=A5=20=EC=A7=84=ED=96=89=EC=A4=91=20?= =?UTF-8?q?=20-=20=EB=A9=94=EC=8B=9C=EC=A7=80=20=EB=B6=84=EC=84=9D=20?= =?UTF-8?q?=EA=B8=B0=EB=8A=A5=EC=9D=B4=20bean=20=EC=B4=88=EA=B8=B0?= =?UTF-8?q?=ED=99=94=EC=8B=9C=20=EA=B8=B0=EC=A1=B4=20=ED=94=84=EB=A1=9C?= =?UTF-8?q?=EC=84=B8=EC=8A=A4=EC=99=80=20=EC=A4=91=EB=B3=B5=EB=90=98?= =?UTF-8?q?=EB=8A=94=20=EB=B6=80=EB=B6=84=EC=9D=B4=20=EC=9E=88=EC=9C=BC?= =?UTF-8?q?=EB=AF=80=EB=A1=9C=20=EC=88=98=EC=A0=95=20=ED=95=84=EC=9A=94?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- build.gradle | 1 - src/docs/script/parse-message.sh | 17 + src/docs/settings-examples/dfxagent.json | 949 ++++++++++++++++-- .../com/bsmlab/dfx/agent/DfxAgentRunner.java | 41 +- .../agent/config/DfxAgentConfiguration.java | 2 +- src/main/resources/application.yml | 7 +- 6 files changed, 896 insertions(+), 121 deletions(-) create mode 100644 src/docs/script/parse-message.sh diff --git a/build.gradle b/build.gradle index 48ed166..8ec3115 100644 --- a/build.gradle +++ b/build.gradle @@ -46,7 +46,6 @@ repositories { url = 'https://maven.cubrid.org' } } - dependencies { implementation 'org.springframework.boot:spring-boot-starter-jdbc' implementation 'org.springframework.boot:spring-boot-starter-web' diff --git a/src/docs/script/parse-message.sh b/src/docs/script/parse-message.sh new file mode 100644 index 0000000..01e1a01 --- /dev/null +++ b/src/docs/script/parse-message.sh @@ -0,0 +1,17 @@ +#!/bin/bash + +AGENT_HOME=/home/dfxagent/agent +SETTING_FILE=$AGENT_HOME/conf/settings.json + +PARSE_MESSAGE_FILE_OPTION=$1 +OUTPUT_OPTION="" + +if [ -n "$2" ]; then + OUTPUT_OPTION=$2 +fi + +# ๐ŸŸข ์‹คํ–‰ ๋ช…๋ น +echo "java -jar $AGENT_HOME/lib/dfxagent.jar \ + --setting.file=$SETTING_FILE \ + $PARSE_MESSAGE_FILE_OPTION \ + $OUTPUT_OPTION" diff --git a/src/docs/settings-examples/dfxagent.json b/src/docs/settings-examples/dfxagent.json index 94c427f..d2278cf 100644 --- a/src/docs/settings-examples/dfxagent.json +++ b/src/docs/settings-examples/dfxagent.json @@ -1,135 +1,870 @@ { - "myHostId": "first-agent", - "myListenPort": 16801, + "description": "๋กœ์ปฌ ํ…Œ์ŠคํŠธ์šฉ", + "myHostId": "local-dev-oracle", + "myListenPort": 17801, "knownAgentList": [ { - "hostId": "second-agent", - "hostName": "mkami.foxsoft.kr", - "listenPort": 16801, + "hostId": "fox-ami-dev-cubrid", + "hostName": "ami.foxsoft.kr", + "listenPort": 17801, "dropBoxIdList": [ - "drop1", - "drop2" - ] - }, - { - "hostId": "third-agent", - "hostName": "defree.co.kr", - "listenPort": 16801, - "dropBoxIdList": [ - "drop3", - "drop4" + "dropbox-fox-ami-dev-cubrid-receive-code-list", + "dropbox-fox-ami-dev-cubrid-receive-comm-meth-list", + "dropbox-fox-ami-dev-cubrid-receive-dept-list", + "dropbox-fox-ami-dev-cubrid-receive-err-cause-list", + "dropbox-fox-ami-dev-cubrid-receive-err-type-list", + "dropbox-fox-ami-dev-cubrid-receive-kdn-dept-list", + "dropbox-fox-ami-dev-cubrid-receive-order-list", + "dropbox-fox-ami-dev-cubrid-receive-work-group-list", + "dropbox-fox-ami-dev-cubrid-receive-fac-err-cur-dcu-list", + "dropbox-fox-ami-dev-cubrid-receive-fac-err-cur-modem-list", + "dropbox-fox-ami-dev-cubrid-receive-fcty-danger-info-list", + "dropbox-fox-ami-dev-cubrid-receive-fcty-cs-meter-info-list", + "dropbox-fox-ami-dev-cubrid-receive-fcty-dcu-info-list", + "dropbox-fox-ami-dev-cubrid-receive-sigong-master-list", + "dropbox-fox-ami-dev-cubrid-receive-sigong-sbcn-co-list", + "dropbox-fox-ami-dev-cubrid-receive-sigong-order-new-modem-list", + "dropbox-fox-ami-dev-cubrid-receive-sigong-order-sig-modem-list", + "dropbox-fox-ami-dev-cubrid-receive-meter-ndl-lst-list", + "dropbox-fox-ami-dev-cubrid-receive-mtr-mst-list", + "dropbox-fox-ami-dev-cubrid-receive-mtr-mst-detail-list", + "dropbox-fox-ami-dev-cubrid-receive-mtr-inst-list", + "dropbox-fox-ami-dev-cubrid-receive-ann-mtr-insp-expr-list", + "dropbox-fox-ami-dev-cubrid-receive-inln-co-list", + "dropbox-fox-ami-dev-cubrid-receive-sbcn-co-list", + "dropbox-fox-ami-dev-cubrid-receive-equip-mtrl-list", + "dropbox-fox-ami-dev-cubrid-receive-mng-plce-list", + "dropbox-fox-ami-dev-cubrid-receive-pckn-list", + "dropbox-fox-ami-dev-cubrid-receive-mtrl-tp-list" ] } ], + "statusChecker": { + "cron": "0/5 * * * * *" + }, "dataSourceConfig": [ { - "dataSourceId": "oracle", - "driverClassName": "org.postgresql.Driver", - "url": "jdbc:oracle:thin:@192.168.0.221:1521:xe", + "dataSourceId": "ds-oracle", + "driverClassName": "oracle.jdbc.driver.OracleDriver", + "url": "jdbc:oracle:thin:@mkami.foxsoft.kr:1521:xe", "username": "ami", - "password": "fox12#$%" - }, - { - "dataSourceId": "mochastory", - "driverClassName": "com.mysql.jdbc.Driver", - "url": "jdbc:mysql://bsm-lab.com:3306/MOCHASTORY?allowPublicKeyRetrieval=true", - "username": "MOCHASTORY", - "password": "MOCHASTORY" + "password": "fox12#$%", + "maximumRowForTransaction": 1000 } ], "sqlMapperLocations": [ - "D:/projects/bsm-lab/dfx/dfxagent/src/docs/mapper-examples/**/*.xml" + "/home/dfxagent/agent/conf/mappers/**/*.xml" ], - "dropBox": { + "logging": { + "logDirectory": "/home/dfxagent/agent/logs", + "logFileName": "dfxagent.log", + "logName": "DFX_LOG", + "maxHistory": 30, + "logPattern": "%d{yyyy-MM-dd HH:mm:ss} [%thread] %-5level %logger{36} - %msg%n", + "rootLogLevel": "DEBUG", + "packages": [ + { + "com.bsmlab.dfx.agent": "DEBUG", + "jdbc.sqlonly": "DEBUG", + "org.springframework": "INFO" + } + ] + }, + "dropBoxConfig": { "receivedMessageStorageRoot": "D:/projects/bsm-lab/dfx/dfxagent/src/docs/messages/received", "processedMessageStorageRoot": "D:/projects/bsm-lab/dfx/dfxagent/src/docs/messages/processed", "failureMessageStorageRoot": "D:/projects/bsm-lab/dfx/dfxagent/src/docs/messages/failure", + "threadPoolSize": 300, + "retentionDaysOfProcessedMessage": 60, "dropBoxList": [ { - "dropBoxId": "save-violation-history", + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-atch-file-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.insertAtchFileListForReceive", + "description": "๊ณตํ†ต ์ฒจ๋ถ€ํŒŒ์ผ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-atch-file-detail-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.insertAtchFileListDetailForReceive", + "description": "๊ณตํ†ต ์ฒจ๋ถ€ํŒŒ์ผ์ƒ์„ธ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-work-act-dcu-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.insertWorkActDcuListForReceive", + "description": "์œ ์ง€๊ด€๋ฆฌ ์กฐ์น˜๋‚ด์šฉ_DCU ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-work-act-modem-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.insertWorkActModemListForReceive", + "description": "์œ ์ง€๊ด€๋ฆฌ ์กฐ์น˜๋‚ด์šฉ_๋ชจ๋Ž€ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-etc-act-dcu-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.insertEtcActDcuListForReceive", + "description": "์œ ์ง€๊ด€๋ฆฌ ๊ธฐํƒ€ ์กฐ์น˜_DCU ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-etc-act-modem-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.insertEtcActModemListForReceive", + "description": "์œ ์ง€๊ด€๋ฆฌ ๊ธฐํƒ€ ์กฐ์น˜_๋ชจ๋Ž€๊ณ„๊ธฐ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-work-act-svc-cd-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.insertWorkActSvcCdListForReceive", + "description": "์œ ์ง€๊ด€๋ฆฌ ์กฐ์น˜๋‚ด์šฉ_๋…ธ์ž„ํ’ˆ๋ชฉ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-sigong-act-dcu-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.insertSigongActDcuListForReceive", + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ์‹œ๊ณต์กฐ์น˜๋‚ด์—ญ_DCU ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-sigong-act-modem-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.insertSigongActModemListForReceive", + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ์‹œ๊ณต์กฐ์น˜๋‚ด์—ญ_๋ชจ๋Ž€ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-sigong-unable-dcu-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.insertSigongUnableDcuListForReceive", + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ์„ค์น˜๋ถˆ๊ฐ€/์ฒ ๊ฑฐ๋‚ด์—ญ_DCU ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-sigong-unable-modem-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.insertSigongUnableModemListForReceive", + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ์„ค์น˜๋ถˆ๊ฐ€/์ฒ ๊ฑฐ๋‚ด์—ญ_๋ชจ๋Ž€ ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-meter-ndl-act-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.emr.insertMeterNdlActListForReceive", + "description": "์ž„์‹œ์กฐ์น˜ ๋‹น์›”๊ฒ€์นจ์ •๋ณด(๋ฐ์ดํ„ฐ) ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-remo-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrRemoListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์„ค ์ž‘์—… ์ƒ์„ธ ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-ct-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrCtListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† ๋ณ€๋ฅ˜๊ธฐ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-ct-detail-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrCtDetailListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† ๋ณ€๋ฅ˜๊ธฐ ์ƒ์„ธ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-ts-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrTsListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† ํƒ€์ž„์Šค์œ„์น˜ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-ms-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrMsListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† ์ „์ž์ ‘์ด‰๊ธฐ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-mb-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrMbListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† ๊ณ„๊ธฐํ•จ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-spd-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrSpdListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ถ€์† SPD ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-gd-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrGdListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ์ง€์นจ์ž‘์—…์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-sl-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrSlListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ด‰์ธ์ž‘์—…์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-pt-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrPtListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๋ณ€์„ฑ๊ธฐ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-mtr-ttb-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.insertMtrTtbListForReceive", + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ์‹œํ—˜์šฉ๋‹จ์ž๋Œ€ ์ž‘์—… ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-equip-base-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertEquipBaseListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๊ธฐ๋ณธ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-equip-move-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertEquipMoveListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ์ด๋ ฅ์ •๋ณด ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-dlvg-dcu-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertDlvgDcuListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋‚ฉํ’ˆ๋งˆ์Šคํ„ฐ_DCU ์ˆ˜์‹ " + }, + { + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-dlvg-modm-list", "taskType": "RECEIVE_DB_TO_DB_SAVE", - "dataSourceId": "dfcms", - "sqlId": "dfcms.violation.insertViolationHistory" + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertDlvgModmListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋‚ฉํ’ˆ๋งˆ์Šคํ„ฐ_๋ชจ๋Ž€ ์ˆ˜์‹ " }, { - "dropBoxId": "receive-work-image-file", - "taskType": "RECEIVE_FILE", - "saveDirectoryRoot": "D:\\projects\\bsm-lab\\dfx\\run\\receive_file" + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-dlvg-metr-list", + "taskType": "RECEIVE_DB_TO_DB_SAVE", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertDlvgMetrListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋‚ฉํ’ˆ๋งˆ์Šคํ„ฐ_๊ณ„๊ธฐ ์ˆ˜์‹ " }, { - "dropBoxId": "save-work-image-file-info", + "dropBoxId": "dropbox-fox-mkami-dev-oracle-receive-dlvg-lte-modm-list", "taskType": "RECEIVE_DB_TO_DB_SAVE", - "dataSourceId": "dfcms", - "sqlId": "dfcms.file.insertFileInfo" + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.insertDlvgLteModmListForReceive", + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋‚ฉํ’ˆ๋งˆ์Šคํ„ฐ_LTE๋ชจ๋Ž€ ์ˆ˜์‹ " } ] }, - "postman": [ - { - "postmanId": "postman1", - "taskType": "DB_READ_THEN_SEND", - "action": { - "type": "TRIGGER", - "command": "runSelectSomeThenSend", - "parametersKeyList": [ - "REG_DATE_FROM", - "REG_DATE_TO" - ] - }, - "message": { - "messageType": "TRANSFER_DB_TO_DB", - "dataSourceId": "dfcms", - "sqlId": "dfcms.selectSome" - }, - "recipientHostId": "third-agent", - "recipientDropBoxId": "drop3", - "routingHostIdList": [ - "first-agent", - "second-agent", - "third-agent" - ] - }, - { - "postmanId": "postman-oracle-tto-bd-10", - "taskType": "DB_READ_THEN_SEND", - "action": { - "type": "SCHEDULED", - "cron": "0 */1 * * * *" - }, - "message": { - "messageType": "TRANSFER_DB_TO_DB", - "dataSourceId": "oracle", - "sqlId": "address.postman.oracle.ttoBd.selectTtoBd10" - }, - "recipientHostId": "third-agent", - "recipientDropBoxId": "drop3", - "routingHostIdList": [ - "first-agent", - "second-agent", - "third-agent" - ] - }, - { - "postmanId": "postman3", - "taskType": "FILE_READ_THEN_SEND", - "action": { - "type": "SCHEDULED", - "cron": "0 1 3 * * *" - }, - "message": { - "messageType": "TRANSFER_FILE", - "watchDirectory": "D:\\projects\\bsm-lab\\dfx\\run\\send_file", - "metaDataDataSourceId": "save-work-image-file-info", - "metaDataSqlId": "dfcms.file.selectFileInfo", - "metaDropBoxId": "save-work-image-file-info" - }, - "recipientHostId": "third-agent", - "recipientDropBoxId": "drop4", - "routingHostIdList": [ - "first-agent", - "second-agent", - "third-agent" - ] - } - ] -} \ No newline at end of file + "postmanConfig": { + "threadPoolSize": 30, + "postmanList": [ + { + "postmanId": "postman-fox-mkami-dev-oracle-send-code-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "1 1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectCodeListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateCodeListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-code-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_CODE ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-comm-meth-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "2 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectCommMethListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateCommMethListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-comm-meth-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_COMM_METH ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-dept-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "3 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectDeptListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateDeptListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-dept-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_DEPT ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-err-cause-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "4 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectErrCauseListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateErrCauseListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-err-cause-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_ERR_CAUSE ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-err-type-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "5 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectErrTypeListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateErrTypeListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-err-type-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_ERR_TYPE ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-kdn-dept-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "6 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectKdnDeptListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateKdnDeptListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-kdn-dept-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_KDN_DEPT ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-order-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "7 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectOrderListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateOrderListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-order-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_ORDER ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-work-group-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectWorkGroupListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateWorkGroupListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-work-group-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต T_WORK_GROUP ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fac-err-cur-dcu-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "31 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFacErrCurDcuListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFacErrCurDcuListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fac-err-cur-dcu-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ์ž‘์—…๋Œ€์ƒ_DCU ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fac-err-cur-modem-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "32 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFacErrCurModemListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFacErrCurModemListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fac-err-cur-modem-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ์ž‘์—…๋Œ€์ƒ_๋ชจ๋Ž€ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fcty-danger-info-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "33 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFctyDangerInfoListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFctyDangerInfoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fcty-danger-info-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ์œ„ํ—˜๋ถˆ๊ฐ€๊ฐœ์†Œ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fac-err-clr-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "34 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFacErrClrListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFacErrClrListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fac-err-clr-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ๊ณ„๊ธฐ์žฅ์• ์ฒ˜๋ฆฌ์™„๋ฃŒ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fcty-cs-meter-info-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "35 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFctyCsMeterInfoListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFctyCsMeterInfoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fcty-cs-meter-info-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ์„ค๋น„๊ณ„๊ธฐ์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-fcty-dcu-info-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "36 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.obs.selectFctyDcuInfoListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.obs.updateFctyDcuInfoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-fcty-dcu-info-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์œ ์ง€๊ด€๋ฆฌ ์„ค๋น„DCU์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-sigong-master-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "37 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.selectSigongMasterListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.cst.updateSigongMasterListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-sigong-master-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ๊ณต์‚ฌ๊ธฐ๋ณธ์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-sigong-sbcn-co-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "37 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.selectSigongSbcnCoListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.cst.updateSigongSbcnCoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-sigong-sbcn-co-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ๊ณต์‚ฌ๋ณ„ ํ•˜๋„๊ธ‰์—…์ฒด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-sigong-order-new-modem-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "37 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.selectSigongOrderNewModemListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.cst.updateSigongOrderNewModemListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-sigong-order-new-modem-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ๋Œ€์ƒ์ •๋ณด_๋ชจ๋Ž€_์‹ ๊ทœ๊ณต์‚ฌ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-sigong-order-sig-modem-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "37 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.cst.selectSigongOrderSigModemListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.cst.updateSigongOrderSigModemListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-sigong-order-sig-modem-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "AMI๊ณต์‚ฌ๊ด€๋ฆฌ ๋Œ€์ƒ์ •๋ณด_๋ชจ๋Ž€_์‹ ํ˜ธ๋ณด๊ฐ• ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-meter-ndl-lst-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "38 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.emr.selectMeterNdlLstListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.emr.updateMeterNdlLstListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-meter-ndl-lst-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์ž„์‹œ์กฐ์น˜ ์ „์›”๊ฒ€์นจ์ •๋ณด(๋ฐ์ดํ„ฐ) ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-mtr-mst-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "39 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.selectMtrMstListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtr.updateMtrMstListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-mtr-mst-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๊ณ„๊ธฐ์ž‘์—…๊ณต์‚ฌ์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-mtr-mst-detail-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "39 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.selectMtrMstDetailListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtr.updateMtrMstDetailListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-mtr-mst-detail-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ๊ณ„๊ธฐ์ž‘์—…๊ณต์‚ฌํ˜„์žฅ์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-mtr-inst-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "39 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.selectMtrInstListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtr.updateMtrInstListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-mtr-inst-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ์ž‘์—… ๋Œ€์ƒ ์ •๋ณด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-ann-mtr-insp-expr-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "39 0/1 * * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtr.selectAnnMtrInspExprListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtr.updateAnnMtrInspExprListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-ann-mtr-insp-expr-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณ„๊ธฐ๊ด€๋ฆฌ ์—ฐ๊ฐ„๋Œ€์ƒ์‹คํšจ๊ณ„๊ธฐ๋ชฉ๋ก ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-inln-co-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectInlnCoListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateInlnCoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-inln-co-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต ๋‚ด์„ ์—…์ฒด ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-sbcn-co-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.fmp.cdm.selectSbcnCoListForSend", + "postProcessingSqlId": "com.kdn.mkami.fmp.cdm.updateSbcnCoListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-sbcn-co-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "๊ณตํ†ต ํ•˜๋„๊ธ‰์‚ฌ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-equip-mtrl-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.selectEquipMtrlListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtl.updateEquipMtrlListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-equip-mtrl-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋งˆ์Šคํ„ฐ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-mng-plce-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.selectMngPlceListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtl.updateMngPlceListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-mng-plce-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ๋ณด๊ด€์žฅ์†Œ ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-pckn-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.selectPcknListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtl.updatePkcnListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-pckn-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์ž์žฌ๊ด€๋ฆฌ ํŒจํ‚น ์†ก์‹ " + }, + { + "postmanId": "postman-fox-mkami-dev-oracle-send-mtrl-tp-list", + "taskType": "DB_READ_THEN_SEND", + "action": { + "type": "SCHEDULED", + "cron": "8 1 0 * * *" + }, + "message": { + "messageType": "TRANSFER_DB_TO_DB", + "dataSourceId": "ds-oracle", + "sqlId": "com.kdn.mkami.mob.mtl.selectMtrlTpListForSend", + "postProcessingSqlId": "com.kdn.mkami.mob.mtl.updateMtrlTpListTransferDone" + }, + "recipientHostId": "fox-ami-dev-cubrid", + "recipientDropBoxId": "dropbox-fox-ami-dev-cubrid-receive-mtrl-tp-list", + "routingHostIdList": [ + "fox-ami-dev-cubrid" + ], + "description": "์ž์žฌ๊ด€๋ฆฌ ์ž์žฌ์œ ํ˜• ์†ก์‹ " + } + ] + } +} diff --git a/src/main/java/com/bsmlab/dfx/agent/DfxAgentRunner.java b/src/main/java/com/bsmlab/dfx/agent/DfxAgentRunner.java index 541c009..0ee84bf 100644 --- a/src/main/java/com/bsmlab/dfx/agent/DfxAgentRunner.java +++ b/src/main/java/com/bsmlab/dfx/agent/DfxAgentRunner.java @@ -41,10 +41,24 @@ public class DfxAgentRunner implements ApplicationRunner { // command line ์‹คํ–‰ ์ค‘ --check-config ๊ฐ€ ์žˆ๋Š” ๊ฒฝ์šฐ settings.json ์„ ๋กœ๋“œํ•˜์—ฌ DB ์—ฐ๊ฒฐ, knownAgent ์—ฐ๊ฒฐ ํ…Œ์ŠคํŠธ๋ฅผ ์ง„ํ–‰ํ•œ๋‹ค. // java -jar $AGENT_HOME/lib/dfxagent.jar --setting.check --setting.file=$AGENT_HOME/conf/settings.json & if(args.containsOption("setting.check")) { - this.checkConfig(args); + try { + this.checkConfig(args); + } + catch(Exception e) { + System.err.println(e.getLocalizedMessage()); + System.exit(2); + } + System.exit(0); } else if(args.containsOption("parse.message.file")) { - this.parseMessageFile(args); + try { + this.parseMessageFile(args); + } + catch(Exception e) { + System.err.println(e.getLocalizedMessage()); + System.exit(2); + } + System.exit(0); } } @@ -77,27 +91,32 @@ public class DfxAgentRunner implements ApplicationRunner { ObjectMapper objectMapper = new ObjectMapper(); String parsedString = objectMapper.writerWithDefaultPrettyPrinter().writeValueAsString(receiveMessageDto); outputStream.write(parsedString.getBytes()); + if(outputStream == System.out) { + outputStream.flush(); + } + else { + outputStream.close(); + } } catch(FileNotFoundException e) { this.print("์˜ค๋ฅ˜๊ฐ€ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค."); this.print(e.getLocalizedMessage()); - this.print("์ ๊ฒ€์„ ์ข…๋ฃŒํ•ฉ๋‹ˆ๋‹ค."); System.exit(2); - } catch (ClassNotFoundException e) { + } + catch (ClassNotFoundException e) { this.print("์˜ค๋ฅ˜๊ฐ€ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค."); this.print(e.getLocalizedMessage()); - this.print("์ ๊ฒ€์„ ์ข…๋ฃŒํ•ฉ๋‹ˆ๋‹ค."); System.exit(2); - } catch (JsonProcessingException e) { + } + catch (JsonProcessingException e) { this.print("์˜ค๋ฅ˜๊ฐ€ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค."); this.print(e.getLocalizedMessage()); - this.print("์ ๊ฒ€์„ ์ข…๋ฃŒํ•ฉ๋‹ˆ๋‹ค."); - } catch (IOException e) { + System.exit(2); + } + catch (IOException e) { this.print("์˜ค๋ฅ˜๊ฐ€ ํฌํ•จ๋˜์–ด ์žˆ์Šต๋‹ˆ๋‹ค."); this.print(e.getLocalizedMessage()); - this.print("์ ๊ฒ€์„ ์ข…๋ฃŒํ•ฉ๋‹ˆ๋‹ค."); - } finally { - outputStream.close(); + System.exit(2); } this.print("-----------------------"); this.print("๋ณ€ํ™˜์„ ์ข…๋ฃŒํ•ฉ๋‹ˆ๋‹ค."); diff --git a/src/main/java/com/bsmlab/dfx/agent/config/DfxAgentConfiguration.java b/src/main/java/com/bsmlab/dfx/agent/config/DfxAgentConfiguration.java index 55ed46f..29d09bb 100644 --- a/src/main/java/com/bsmlab/dfx/agent/config/DfxAgentConfiguration.java +++ b/src/main/java/com/bsmlab/dfx/agent/config/DfxAgentConfiguration.java @@ -113,7 +113,7 @@ public class DfxAgentConfiguration { List dataSourceConfigList = agentConfigReader.getAgentConfigDto().getDataSourceConfig(); for(AgentConfigDto.DataSourceConfig dataSourceConfig : dataSourceConfigList) { try { - BasicDataSource dataSource = createBasicDataSource(dataSourceConfig); + BasicDataSource dataSource = this.createBasicDataSource(dataSourceConfig); SqlSessionFactoryBean sqlSessionFactoryBean = new RefreshableSqlSessionFactoryBean();//new SqlSessionFactoryBean(); org.apache.ibatis.session.Configuration mybatisConfiguration = new org.apache.ibatis.session.Configuration(); mybatisConfiguration.setJdbcTypeForNull(JdbcType.NULL); diff --git a/src/main/resources/application.yml b/src/main/resources/application.yml index 3877139..1c7d3ad 100644 --- a/src/main/resources/application.yml +++ b/src/main/resources/application.yml @@ -13,4 +13,9 @@ logging: org.springframework.boot: ERROR com.bsmlab.dfx.agent: DEBUG com.bsmlab.dfx.agent.DfxAgentApplication: WARN - +log4jdbc: + dump: + sql: + resultsettable: false + resultset: false + methodcall: false