SteamWar/SpigotCore
Archiviert
13
0

Add logfile to exception
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Dieser Commit ist enthalten in:
Lixfel 2024-01-17 12:13:33 +01:00
Ursprung 7679998285
Commit 1fdb7d8e0d

Datei anzeigen

@ -30,9 +30,7 @@ import org.eclipse.openj9.criu.CRIUSupport;
import org.eclipse.openj9.criu.JVMCRIUException; import org.eclipse.openj9.criu.JVMCRIUException;
import sun.misc.Signal; import sun.misc.Signal;
import java.io.DataInputStream; import java.io.*;
import java.io.File;
import java.io.IOException;
import java.net.InetAddress; import java.net.InetAddress;
import java.nio.file.FileSystems; import java.nio.file.FileSystems;
import java.nio.file.Files; import java.nio.file.Files;
@ -109,6 +107,11 @@ public class CheckpointUtils {
criu.checkpointJVM(); criu.checkpointJVM();
} catch (JVMCRIUException e) { } catch (JVMCRIUException e) {
Bukkit.shutdown(); Bukkit.shutdown();
Path logfile = path.resolve("criu.log");
if(logfile.toFile().exists())
throw new IllegalStateException("Could not create checkpoint, criu log:\n" + new String(Files.readAllBytes(logfile)), e);
throw e; throw e;
} }