From f9b70d590254813c9371290ed96a27eca28ae6c3 Mon Sep 17 00:00:00 2001 From: hengyunabc Date: Fri, 27 Nov 2020 11:06:01 +0800 Subject: [PATCH] update doc about tunnel/arthas properties --- site/src/site/sphinx/arthas-properties.md | 7 ++++++- site/src/site/sphinx/en/arthas-properties.md | 8 +++++++- site/src/site/sphinx/en/spring-boot-starter.md | 14 +++++++++++++- site/src/site/sphinx/en/tunnel.md | 4 +++- site/src/site/sphinx/spring-boot-starter.md | 13 ++++++++++++- site/src/site/sphinx/tunnel.md | 5 +++-- 6 files changed, 44 insertions(+), 7 deletions(-) diff --git a/site/src/site/sphinx/arthas-properties.md b/site/src/site/sphinx/arthas-properties.md index d7af00d3..17fbbd64 100644 --- a/site/src/site/sphinx/arthas-properties.md +++ b/site/src/site/sphinx/arthas-properties.md @@ -10,13 +10,18 @@ Arthas Properties ## 支持的配置项 +> 注意配置必须是`驼峰`的,和spring boot的`-`风格不一样。spring boot应用才同时支持`驼峰` 和 `-`风格的配置。 ``` #arthas.config.overrideAll=true arthas.telnetPort=3658 arthas.httpPort=8563 -arthas.ip=localhost +arthas.ip=127.0.0.1 +# seconds +arthas.sessionTimeout=1800 + +#arthas.appName=demoapp #arthas.tunnelServer=ws://127.0.0.1:7777/ws #arthas.agentId=mmmmmmyiddddd ``` diff --git a/site/src/site/sphinx/en/arthas-properties.md b/site/src/site/sphinx/en/arthas-properties.md index 31276424..c56deb4f 100644 --- a/site/src/site/sphinx/en/arthas-properties.md +++ b/site/src/site/sphinx/en/arthas-properties.md @@ -8,12 +8,18 @@ The `arthas.properties` file is in the arthas directory. ## Supported configuration items +> Note that the configuration must be `camel case`, which is different from the `-` style of spring boot. Only the spring boot application supports both `camel case` and `-` style configuration. + ``` #arthas.config.overrideAll=true arthas.telnetPort=3658 arthas.httpPort=8563 -arthas.ip=localhost +arthas.ip=127.0.0.1 +# seconds +arthas.sessionTimeout=1800 + +#arthas.appName=demoapp #arthas.tunnelServer=ws://127.0.0.1:7777/ws #arthas.agentId=mmmmmmyiddddd ``` diff --git a/site/src/site/sphinx/en/spring-boot-starter.md b/site/src/site/sphinx/en/spring-boot-starter.md index 49ac6a55..d9f7207f 100644 --- a/site/src/site/sphinx/en/spring-boot-starter.md +++ b/site/src/site/sphinx/en/spring-boot-starter.md @@ -75,4 +75,16 @@ public class ArthasAttachExample { } } -``` \ No newline at end of file +``` + + +You can also configure properties: + +```java + HashMap configMap = new HashMap(); + configMap.put("arthas.appName", "demo"); + configMap.put("arthas.tunnelServer", "ws://127.0.0.1:7777/ws"); + ArthasAgent.attach(configMap); +``` + +> Note that the configuration must be `camel case`, which is different from the `-` style of spring boot. Only the spring boot application supports both `camel case` and `-` style configuration. \ No newline at end of file diff --git a/site/src/site/sphinx/en/tunnel.md b/site/src/site/sphinx/en/tunnel.md index 8bcab228..8d3277eb 100644 --- a/site/src/site/sphinx/en/tunnel.md +++ b/site/src/site/sphinx/en/tunnel.md @@ -8,7 +8,9 @@ For example, in streaming computing, Java processes can be started on different In this case, Arthas Tunnel Server/Client can be used. -Reference: [Web Console](web-console.md) +Reference: +* [Web Console](web-console.md) +* [Arthas Spring Boot Starter](spring-boot-starter.md) ### Download and deploy arthas tunnel server diff --git a/site/src/site/sphinx/spring-boot-starter.md b/site/src/site/sphinx/spring-boot-starter.md index 57779595..5e0213fa 100644 --- a/site/src/site/sphinx/spring-boot-starter.md +++ b/site/src/site/sphinx/spring-boot-starter.md @@ -77,4 +77,15 @@ public class ArthasAttachExample { } } -``` \ No newline at end of file +``` + +也可以配置属性: + +```java + HashMap configMap = new HashMap(); + configMap.put("arthas.appName", "demo"); + configMap.put("arthas.tunnelServer", "ws://127.0.0.1:7777/ws"); + ArthasAgent.attach(configMap); +``` + +> 注意配置必须是`驼峰`的,和spring boot的`-`风格不一样。spring boot应用才同时支持`驼峰` 和 `-`风格的配置。 \ No newline at end of file diff --git a/site/src/site/sphinx/tunnel.md b/site/src/site/sphinx/tunnel.md index 29414e23..782bd158 100644 --- a/site/src/site/sphinx/tunnel.md +++ b/site/src/site/sphinx/tunnel.md @@ -7,8 +7,9 @@ Arthas Tunnel 在这种情况下,可以使用Arthas Tunnel Server/Client。 -参考: [Web Console](web-console.md) - +参考: +* [Web Console](web-console.md) +* [Arthas Spring Boot Starter](spring-boot-starter.md) ### 下载部署arthas tunnel server