SteamWar/BungeeCore
Archiviert
13
2

Improve error logging
Alle Prüfungen waren erfolgreich
SteamWarCI Build successful

Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Lixfel 2022-03-30 16:49:40 +02:00
Ursprung 82bd4b752d
Commit 5838f6ed69
2 geänderte Dateien mit 9 neuen und 9 gelöschten Zeilen

Datei anzeigen

@ -85,13 +85,8 @@ public class ErrorLogger extends Handler {
static {
List<String> contains = new ArrayList<>();
contains.add("ServerConnector");
contains.add("InitialHandler");
contains.add("UpstreamBridge");
contains.add("DownstreamBridge");
contains.add(" took ");
contains.add("No client connected for pending server!");
contains.add("Error authenticating ");
contains.add("read timed out");
ignoreContains = Collections.unmodifiableList(contains);
}
}

Datei anzeigen

@ -35,6 +35,7 @@ import net.dv8tion.jda.api.JDABuilder;
import net.dv8tion.jda.api.OnlineStatus;
import net.dv8tion.jda.api.entities.Activity;
import net.dv8tion.jda.api.entities.Guild;
import net.dv8tion.jda.api.exceptions.ErrorResponseException;
import net.dv8tion.jda.api.hooks.ListenerAdapter;
import net.dv8tion.jda.api.requests.restaction.CommandListUpdateAction;
import net.dv8tion.jda.api.utils.MemberCachePolicy;
@ -93,9 +94,13 @@ public class SteamwarDiscordBot {
EventManager.update();
SchematicsManager.update();
ProxyServer.getInstance().getScheduler().schedule(BungeeCore.get(), () -> {
try {
activity();
EventManager.update();
SchematicsManager.update();
} catch (ErrorResponseException e) {
//ignored
}
}, 30, 30, TimeUnit.SECONDS);
DiscordRolesMessage.sendMessage();
DiscordRulesMessage.sendMessage();