From ec7c5aea33547692427ac7418cbf5d707a42c0ea Mon Sep 17 00:00:00 2001 From: hengyunabc Date: Fri, 8 Feb 2019 15:18:06 +0800 Subject: [PATCH] change default session timeout to 30min. close #342 --- bin/as.sh | 6 +++--- boot/src/main/java/com/taobao/arthas/boot/Bootstrap.java | 2 +- .../com/taobao/arthas/core/shell/ShellServerOptions.java | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/bin/as.sh b/bin/as.sh index c4846a555..73e2aa0e0 100755 --- a/bin/as.sh +++ b/bin/as.sh @@ -35,8 +35,8 @@ TELNET_PORT="3658" # http port HTTP_PORT="8563" -# telnet session timeout seconds, default 300 -SESSION_TIMEOUT=300 +# telnet session timeout seconds, default 1800 +SESSION_TIMEOUT=1800 # use specify version USE_VERSION= @@ -398,7 +398,7 @@ Options and Arguments: --target-ip The target jvm listen ip, default 127.0.0.1 --telnet-port The target jvm listen telnet port, default 3658 --http-port The target jvm listen http port, default 8563 - --session-timeout The session timeout seconds, default 300 + --session-timeout The session timeout seconds, default 1800 (30min) --arthas-home The arthas home --use-version Use special version arthas --repo-mirror Use special maven repository mirror, value is diff --git a/boot/src/main/java/com/taobao/arthas/boot/Bootstrap.java b/boot/src/main/java/com/taobao/arthas/boot/Bootstrap.java index 12e6365fc..06f09d727 100644 --- a/boot/src/main/java/com/taobao/arthas/boot/Bootstrap.java +++ b/boot/src/main/java/com/taobao/arthas/boot/Bootstrap.java @@ -135,7 +135,7 @@ public class Bootstrap { } @Option(longName = "session-timeout") - @Description("The session timeout seconds, default 300") + @Description("The session timeout seconds, default 1800 (30min)") public void setSessionTimeout(Long sessionTimeout) { this.sessionTimeout = sessionTimeout; } diff --git a/core/src/main/java/com/taobao/arthas/core/shell/ShellServerOptions.java b/core/src/main/java/com/taobao/arthas/core/shell/ShellServerOptions.java index daf5624d7..5ebc5d2c7 100644 --- a/core/src/main/java/com/taobao/arthas/core/shell/ShellServerOptions.java +++ b/core/src/main/java/com/taobao/arthas/core/shell/ShellServerOptions.java @@ -19,7 +19,7 @@ public class ShellServerOptions { /** * Default time, in ms, that a shell session lasts for without being accessed before expiring. */ - public static final long DEFAULT_SESSION_TIMEOUT = 5 * 60 * 1000; // 5 minutes + public static final long DEFAULT_SESSION_TIMEOUT = 30 * 60 * 1000; // 30 minutes /** * Default time, in ms, that a server waits for a client to connect