Server crash stack trace zero

Forgot to commit this for a whiiile
This commit is contained in:
Norbi Peti 2017-11-24 23:53:48 +01:00
parent f8c543017a
commit 0c9dd6f49a
2 changed files with 6 additions and 4 deletions

View file

@ -2,10 +2,10 @@ cache:
directories:
- $HOME/.m2/repository/org/
before_install: | # Wget BuildTools and run if cached folder not found
if [ ! -d "$HOME/.m2/repository/org/spigotmc/spigot/1.12-R0.1-SNAPSHOT" ]; then
if [ ! -d "$HOME/.m2/repository/org/spigotmc/spigot/1.12.2-R0.1-SNAPSHOT" ]; then
wget -O BuildTools.jar https://hub.spigotmc.org/jenkins/job/BuildTools/lastSuccessfulBuild/artifact/target/BuildTools.jar
# grep so that download counts don't appear in log files
java -jar BuildTools.jar --rev 1.12 | grep -vE "[^/ ]*/[^/ ]*\s*KB\s*$" | grep -v "^\s*$"
java -jar BuildTools.jar --rev 1.12.2 | grep -vE "[^/ ]*/[^/ ]*\s*KB\s*$" | grep -v "^\s*$"
fi
language: java
jdk:

View file

@ -125,8 +125,10 @@ public class DiscordPlugin extends JavaPlugin implements IListener<ReadyEvent> {
if (getConfig().getBoolean("serverup", false)) {
sendMessageToChannel(chatchannel, "", new EmbedBuilder().withColor(Color.YELLOW)
.withTitle("Server recovered from a crash - chat connected.").build());
TBMCCoreAPI.SendException("The server crashed!", new Throwable(
"The server shut down unexpectedly. See the log of the previous run for more details."));
val thr = new Throwable(
"The server shut down unexpectedly. See the log of the previous run for more details.");
thr.setStackTrace(new StackTraceElement[0]);
TBMCCoreAPI.SendException("The server crashed!", thr);
} else
sendMessageToChannel(chatchannel, "", new EmbedBuilder().withColor(Color.GREEN)
.withTitle("Server started - chat connected.").build());