geforkt von SteamWar/BungeeCore
Fix inversion + debugoutput
Signed-off-by: Lixfel <agga-games@gmx.de>
Dieser Commit ist enthalten in:
Ursprung
265fa45371
Commit
a8d62d6115
@ -195,6 +195,7 @@ public abstract class Node {
|
|||||||
c = 1;
|
c = 1;
|
||||||
}
|
}
|
||||||
cores = c;
|
cores = c;
|
||||||
|
BungeeCore.get().getLogger().log(Level.INFO, "Adding node " + remote + " with " + cores + " cores.");
|
||||||
|
|
||||||
synchronized (nodes) {
|
synchronized (nodes) {
|
||||||
nodes.add(this);
|
nodes.add(this);
|
||||||
|
@ -40,7 +40,7 @@ public class StatCommand extends BasicCommand {
|
|||||||
try {
|
try {
|
||||||
Process process = new ProcessBuilder("ps", "x").start();
|
Process process = new ProcessBuilder("ps", "x").start();
|
||||||
new BufferedReader(new InputStreamReader(process.getInputStream())).lines().forEach(s -> {
|
new BufferedReader(new InputStreamReader(process.getInputStream())).lines().forEach(s -> {
|
||||||
if (s.contains("--port"))
|
if (!s.contains("--port"))
|
||||||
return;
|
return;
|
||||||
serverCount.compute(
|
serverCount.compute(
|
||||||
s.contains("ssh -L") ? s.substring(s.indexOf("ssh -L") + 6).split(" ")[2] : "local",
|
s.contains("ssh -L") ? s.substring(s.indexOf("ssh -L") + 6).split(" ")[2] : "local",
|
||||||
|
In neuem Issue referenzieren
Einen Benutzer sperren