monitor execution of update installer for errors

This commit is contained in:
idk
2022-10-23 15:35:26 -04:00
parent 5f3a3d46f6
commit 91beec4f75
7 changed files with 131 additions and 15 deletions

View File

@ -39,6 +39,20 @@ public class WindowsUpdatePostProcessor implements UpdatePostProcessor {
String version, File file)
throws IOException {
_log.info("Got an update to post-process");
if (fileType != SU3File.TYPE_ZIP) {
this.positionedFile = moveUpdateInstaller(file);
this.version = version;
if (!hook.compareAndSet(false, true)) {
_log.info("shutdown hook was already set");
return;
}
_log.info("adding shutdown hook");
ctx.addFinalShutdownTask(
new ZipUpdateProcess(ctx, this::getVersion, this::getFile));
}
if (SystemVersion.isWindows()) {
if (type != UpdateType.ROUTER_SIGNED_SU3 &&