Skip to content

Commit

Permalink
Merge pull request #378 from experdb/develop
Browse files Browse the repository at this point in the history
Develop
  • Loading branch information
swbyun authored May 20, 2024
2 parents d5a2ac9 + 42b116d commit a44fdc5
Show file tree
Hide file tree
Showing 9 changed files with 43 additions and 19 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -523,22 +523,37 @@ public void agentCall(List<Map<String, Object>> resultWork, ArrayList<String> CM
try {
String IP = "";
int PORT =0;

if(!CMD.get(0).equals("DB2PG")) {
IP = (String) resultDbconn.get(0).get("ipadr");

// 스케줄 수정 시 마이그레이션 후 배치 실행 후에 배치 실행안되는 버그로 수정(240516)
for(int i=0; i < resultWork.size(); i++) {
if(CMD.get(i).equals("DB2PG")) {
}else {
IP = (String) resultDbconn.get(0).get("ipadr");

AgentInfoVO vo = new AgentInfoVO();
vo.setIPADR(IP);

AgentInfoVO agentInfo = (AgentInfoVO) cmmnServerInfoService.selectAgentInfo(vo);
PORT = agentInfo.getSOCKET_PORT();
}else {
PORT = agentInfo.getSOCKET_PORT();
}
for (int i = 0; i < BCKNM.size(); i++) {
if(BCKNM.get(i).equals("backrest")){
IP = scheduleService.selectIpadr(backrest_scd_id);
}
}
}

// if(!CMD.get(0).equals("DB2PG")) {
// IP = (String) resultDbconn.get(0).get("ipadr");
//
// AgentInfoVO vo = new AgentInfoVO();
// vo.setIPADR(IP);
//
// AgentInfoVO agentInfo = (AgentInfoVO) cmmnServerInfoService.selectAgentInfo(vo);
// PORT = agentInfo.getSOCKET_PORT();
// }else {
// }

for (int i = 0; i < BCKNM.size(); i++) {
if(BCKNM.get(i).equals("backrest")){
IP = scheduleService.selectIpadr(backrest_scd_id);
}
}

/*
* String IP = (String) resultDbconn.get(0).get("ipadr");
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-archive' WHERE OPT_ID = 11;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-archive-type' WHERE OPT_ID = 12;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-diff' WHERE OPT_ID = 13;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-diff' WHERE OPT_ID = 13;
UPDATE T_BACKREST_OPT_I set OPT_NM = 'archive-timeout' where OPT_ID = 7;
UPDATE T_BACKREST_OPT_I set OPT_NM = 'archive-check' where OPT_ID = 8;
Original file line number Diff line number Diff line change
Expand Up @@ -48,7 +48,7 @@ INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(9, 1, 'ar
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(10, 1, 'start-fast', '신속하게 백업을 실행하기 위해 체크포인트를 강제 실행');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(11, 0, 'repo1-retention-archive', '유지할 연속 WAL의 백업 수');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(12, 0, 'repo1-retention-archive-type', 'WAL 보존을 위한 백업 유형');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(13, 0, 'repo1-retention-di ff', '보존할 차등백업 수');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(13, 0, 'repo1-retention-diff', '보존할 차등백업 수'); ff', '보존할 차등백업 수');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(14, 2, 'db-include', '특정 데이터베이스 복원');
INSERT INTO T_BACKREST_OPT_I (OPT_ID, OPT_GBN, OPT_NM, OPT_EXP) VALUES(15, 2, 'db-exclude', '특정 데이터베이스를 제외한 나머지 복원');
Expand All @@ -61,3 +61,4 @@ ALTER TABLE t_rman_restore ADD COLUMN restore_size varchar(10) ;
ALTER TABLE t_rman_restore ADD COLUMN elapsed_time varchar(100) ;
COMMENT ON COLUMN t_rman_restore.restore_size IS '복원_파일_크기';
COMMENT ON COLUMN t_rman_restore.elapsed_time IS '복원_소요시간';
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-archive' WHERE OPT_ID = 11;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-archive-type' WHERE OPT_ID = 12;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-diff' WHERE OPT_ID = 13;
UPDATE T_BACKREST_OPT_I SET OPT_NM = 'repo1-retention-diff' WHERE OPT_ID = 13;
UPDATE T_BACKREST_OPT_I set OPT_NM = 'archive-timeout' where OPT_ID = 7;
UPDATE T_BACKREST_OPT_I set OPT_NM = 'archive-check' where OPT_ID = 8;
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@
, C.IPADR
, A.EXE_GRP_SN
, A.SCD_NM
, CC.DB2PG_SYS_ID
, MIN(A.EXE_SN) AS EXE_SN
, MAX(A.EXE_RSLT_CD) AS EXE_RSLT_CD
, (SELECT S.DB_SVR_NM FROM T_DBSVR_I S,T_DBSVRIPADR_I D WHERE S.DB_SVR_ID=D.DB_SVR_ID AND D.DB_SVR_IPADR_ID=A.DB_SVR_IPADR_ID)AS DB_SVR_NM
Expand All @@ -85,6 +86,8 @@
, TO_CHAR(TO_CHAR(MAX(A.WRK_END_DTM),'YYYY-MM-DD HH24:MI:SS')::TIMESTAMP - TO_CHAR(MIN(A.WRK_STRT_DTM),'YYYY-MM-DD HH24:MI:SS')::TIMESTAMP, 'HH24시MI분SS초') AS WRK_DTM
FROM T_WRKEXE_G A
LEFT OUTER JOIN T_DBSVRIPADR_I C ON A.DB_SVR_IPADR_ID= C.DB_SVR_IPADR_ID or A.DB_SVR_IPADR_ID=0
LEFT JOIN T_DB2PG_TRSF_WRK_INF BB ON A.WRK_ID = BB.WRK_ID
LEFT JOIN T_DB2PG_SYS_INF CC ON BB.DB2PG_TRG_SYS_ID = CC.DB2PG_SYS_ID AND C.IPADR = CC.IPADR
WHERE 1 = 1
<if test="lgi_dtm_start != null and lgi_dtm_start != '' ">
AND to_char(A.WRK_END_DTM,'YYYY-MM-DD') between #{lgi_dtm_start} and #{lgi_dtm_end}
Expand All @@ -93,10 +96,11 @@
AND A.SCD_NM LIKE #{scd_nm}
</if>
AND A.EXE_RSLT_CD LIKE #{exe_result}
GROUP BY A.EXE_GRP_SN, A.SCD_NM, A.DB_SVR_IPADR_ID,A.SCD_ID,C.IPADR
GROUP BY A.EXE_GRP_SN, A.SCD_NM, A.DB_SVR_IPADR_ID,A.SCD_ID,C.IPADR,CC.DB2PG_SYS_ID
ORDER BY ${order_type} ${order}
)AA
WHERE AA.DB_SVR_NM LIKE #{db_svr_nm} OR AA.DB_SVR_NM IS NULL;
WHERE AA.DB_SVR_NM LIKE #{db_svr_nm} OR AA.DB_SVR_NM IS NULL
AND AA.DB2PG_SYS_ID IS NOT NULL OR AA.DB_SVR_NM IS NOT NULL;
</select>


Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -977,7 +977,7 @@ function fn_search_tableInfo_mig(){
<spring:message code="common.work_name" />
</label>
<div class="col-sm-8">
<input type="text" class="form-control form-control-sm" maxlength="20" id="db2pg_trsf_wrk_nm" name="db2pg_trsf_wrk_nm" onkeyup="fn_checkWord(this,20)" placeholder="20<spring:message code='message.msg188'/>" onchange="fn_checkWrkNm_change_mig();" onblur="this.value=this.value.trim()"/>
<input type="text" class="form-control form-control-sm" maxlength="50" id="db2pg_trsf_wrk_nm" name="db2pg_trsf_wrk_nm" onkeyup="fn_checkWord(this,50)" placeholder="50<spring:message code='message.msg188'/>" onchange="fn_checkWrkNm_change_mig();" onblur="this.value=this.value.trim()"/>
</div>
<div class="col-sm-2">
<button type="button" id="inset_button_data_work" class="btn btn-inverse-danger btn-fw" style="width: 115px;" onclick="fn_check_ddl_reg()"><spring:message code="common.overlap_check" /></button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -568,7 +568,7 @@ function fn_search_tableInfo(){
<spring:message code="common.work_name" />
</label>
<div class="col-sm-8">
<input type="text" class="form-control form-control-sm" maxlength="20" id="db2pg_ddl_wrk_nm" name="db2pg_ddl_wrk_nm" onkeyup="fn_checkWord(this,20)" placeholder='20<spring:message code='message.msg188'/>' onchange="fn_checkWrkNm_change_ddl();" onblur="this.value=this.value.trim()"/>
<input type="text" class="form-control form-control-sm" maxlength="50" id="db2pg_ddl_wrk_nm" name="db2pg_ddl_wrk_nm" onkeyup="fn_checkWord(this,50)" placeholder='50<spring:message code='message.msg188'/>' onchange="fn_checkWrkNm_change_ddl();" onblur="this.value=this.value.trim()"/>
</div>
<div class="col-sm-2">
<button type="button" class="btn btn-inverse-danger btn-fw" style="width: 115px;" onclick="fn_check_reg()"><spring:message code="common.overlap_check" /></button>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -896,7 +896,7 @@ function fn_db2pgAdd(){
<spring:message code="schedule.schedule_name" />
</label>
<div class="col-sm-4">
<input type="text" class="form-control" maxlength="20" id="scd_nm" name="scd_nm" onkeyup="fn_checkWord(this,20)" onblur="this.value=this.value.trim()" placeholder="20<spring:message code='message.msg188'/>" onchange="fn_checkSchNm_change()"/>
<input type="text" class="form-control" maxlength="50" id="scd_nm" name="scd_nm" onkeyup="fn_checkWord(this,50)" onblur="this.value=this.value.trim()" placeholder="50<spring:message code='message.msg188'/>" onchange="fn_checkSchNm_change()"/>
</div>
<div class="col-sm-1_5">
<input class="btn btn-inverse-danger btn-icon-text mdi mdi-lan-connect" style="margin-left:-20px;" type="button" onclick="fn_check();" value='<spring:message code="common.overlap_check" />' />
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,7 @@
</label>

<div class="col-sm-8">
<input type="text" class="form-control" maxlength="20" id="ins_wrk_nm" name="ins_wrk_nm" onkeyup="fn_checkWord(this,20)" placeholder='20<spring:message code='message.msg188'/>' onblur="this.value=this.value.trim()" tabindex=1 required />
<input type="text" class="form-control" maxlength="50" id="ins_wrk_nm" name="ins_wrk_nm" onkeyup="fn_checkWord(this,50)" placeholder='50<spring:message code='message.msg188'/>' onblur="this.value=this.value.trim()" tabindex=1 required />
</div>

<div class="col-sm-2">
Expand Down

0 comments on commit a44fdc5

Please sign in to comment.