Updating logs to provide correct time before reconnecting

This commit is contained in:
Kyle Melton 2017-07-15 13:44:19 -07:00
parent 3e9f6bdd3d
commit 47bfad2c50
1 changed files with 2 additions and 2 deletions

View File

@ -377,7 +377,7 @@ public final class SubDataClient {
log.info.println("The SubData Connection was closed");
int reconnectDelay = host.config.get().getSection("Settings").getSection("SubData").getInt("Reconnect delay", 30);
if (reconnect) {
log.info.println("Attempting to reconnect in 30 seconds");
log.info.println("Attempting to reconnect in " + reconnectDelay + " seconds");
Timer timer = new Timer();
timer.scheduleAtFixedRate(new TimerTask() {
@Override
@ -390,7 +390,7 @@ public final class SubDataClient {
queue.remove(0);
}
} catch (IOException e) {
log.warn.println("Connection was unsuccessful, retrying in 30 seconds");
log.warn.println("Connection was unsuccessful, retrying in " + reconnectDelay + " seconds");
}
}
}, TimeUnit.SECONDS.toMillis(reconnectDelay), TimeUnit.SECONDS.toMillis(reconnectDelay));