This commit is contained in:
bwcx_jzy 2022-12-03 17:20:09 +08:00
parent 3e9ca11f90
commit 6f28db74bf
No known key found for this signature in database
GPG Key ID: 5E48E9372088B9E5

View File

@ -134,7 +134,7 @@ public class DockerSwarmServiceController extends BaseServerController {
//
String uuid = IdUtil.fastSimpleUUID();
File file = FileUtil.file(ServerConfigBean.getInstance().getUserTempPath(), "docker-swarm-log", uuid + ".log");
LogRecorder logRecorder = LogRecorder.builder().file(file).build();
try (LogRecorder logRecorder = LogRecorder.builder().file(file).build()) {
logRecorder.info("start pull {}", dataId);
Consumer<String> logConsumer = logRecorder::append;
parameter.put("charset", CharsetUtil.CHARSET_UTF_8);
@ -148,6 +148,7 @@ public class DockerSwarmServiceController extends BaseServerController {
}
logRecorder.info("pull end");
});
}
return JsonMessage.getString(200, "开始拉取", uuid);
}