[agent][executor]- bug - 4
This commit is contained in:
@@ -131,14 +131,8 @@ public class CommandExecutor {
|
||||
octopusMessage
|
||||
));
|
||||
|
||||
// 缓存 命令处理日志
|
||||
commandExecLogCache.cacheLog(
|
||||
streamKey,
|
||||
process
|
||||
);
|
||||
|
||||
// 等待1秒钟, 使得有时间进行后端任务的完成
|
||||
TimeUnit.SECONDS.sleep(1);
|
||||
//TimeUnit.SECONDS.sleep(1);
|
||||
|
||||
// get the command result must also be a timeout smaller than the process
|
||||
// 此处会把主线程卡死, forever终结
|
||||
@@ -190,8 +184,6 @@ public class CommandExecutor {
|
||||
|
||||
System.out.println("process isAlive = " + process.isAlive());
|
||||
|
||||
// 对线程进行debug
|
||||
commandExecLogCache.debugProcessStreams(process);
|
||||
|
||||
// 任务提前执行结束,或者超过了最长等待时间
|
||||
// 判断命令是否正确处理完成
|
||||
@@ -217,11 +209,19 @@ public class CommandExecutor {
|
||||
.get()
|
||||
);
|
||||
|
||||
// 对线程进行debug
|
||||
commandExecLogCache.debugProcessStreams(process);
|
||||
|
||||
process.destroy();
|
||||
}
|
||||
}
|
||||
|
||||
// 缓存 命令处理日志
|
||||
commandExecLogCache.cacheLog(
|
||||
streamKey,
|
||||
process
|
||||
);
|
||||
|
||||
// 日志操作,如果需要显示回传,需要将日志发送回相应的
|
||||
/*collectCommandLogAndRepeat(
|
||||
streamKey,
|
||||
|
||||
Reference in New Issue
Block a user