From 27bd6a398f88ee8de1b548b66d2f18cdf346b3b2 Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期一, 04 三月 2024 20:15:11 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
Source/UBCS/ubcs-service/ubcs-deploy/src/main/java/com/vci/ubcs/deploy/service/impl/DeployAppsServiceImpl.java | 13 +++++++++++--
1 files changed, 11 insertions(+), 2 deletions(-)
diff --git a/Source/UBCS/ubcs-service/ubcs-deploy/src/main/java/com/vci/ubcs/deploy/service/impl/DeployAppsServiceImpl.java b/Source/UBCS/ubcs-service/ubcs-deploy/src/main/java/com/vci/ubcs/deploy/service/impl/DeployAppsServiceImpl.java
index af4bb01..6ac5349 100644
--- a/Source/UBCS/ubcs-service/ubcs-deploy/src/main/java/com/vci/ubcs/deploy/service/impl/DeployAppsServiceImpl.java
+++ b/Source/UBCS/ubcs-service/ubcs-deploy/src/main/java/com/vci/ubcs/deploy/service/impl/DeployAppsServiceImpl.java
@@ -179,12 +179,12 @@
}
// 鏈粠搴撲腑鏌ヨ鍒帮紝闇�瑕佺敓鎴愭湇鍔′俊鎭繚瀛橀粯璁や俊鎭埌搴撲腑
DeployApps defaultDeployApps = new DeployApps();
- defaultDeployApps.setLogPath(PARENTPATH + deployAppsVO.getName().replace("-","_") + LOGPATH);
+ defaultDeployApps.setLogPath(PARENTPATH + SEPARATOR + deployAppsVO.getName().replace("-","_") + LOGPATH);
defaultDeployApps.setServerName(deployAppsVO.getName());
defaultDeployApps.setStartCmd(CmdConfigEnum.START_CMD.getValue() + deployAppsVO.getName());
defaultDeployApps.setStopCmd(CmdConfigEnum.STOP_CMD.getValue() + deployAppsVO.getName());
defaultDeployApps.setRestartCmd(CmdConfigEnum.RESTART_CMD.getValue() + deployAppsVO.getName());
- defaultDeployApps.setServerPath(PARENTPATH + deployAppsVO.getName().replace("-","_"));
+ defaultDeployApps.setServerPath(PARENTPATH + SEPARATOR + deployAppsVO.getName().replace("-","_"));
int eft = deployAppsMapper.insert(defaultDeployApps);
if (!SqlHelper.retBool(eft)) {
throw new ServiceException("鐢熸垚榛樿鏈嶅姟淇℃伅鍒板簱涓椂澶辫触锛�");
@@ -357,6 +357,15 @@
}
// 绛夊緟鍛戒护鎵ц瀹屾垚
int exitCode = process.waitFor();
+ // 璇诲彇鍛戒护鎵ц鐨勯敊璇緭鍑烘祦
+ BufferedReader errorReader = new BufferedReader(new InputStreamReader(process.getErrorStream()));
+ StringBuilder errorOutput = new StringBuilder();
+ String errorLine;
+ while ((errorLine = errorReader.readLine()) != null) {
+ errorOutput.append(errorLine).append("\n");
+ }
+ String errorOutputString = errorOutput.toString();
+ log.info("閿欒杈撳嚭锛�" + errorOutputString);
log.info("鍛戒护鎵ц缁撴灉锛�" + output.toString()+":"+exitCode);
return output.toString();
}catch (IOException | InterruptedException e){
--
Gitblit v1.10.0