This is an automated email from the ASF dual-hosted git repository.

miaoliyao pushed a commit to branch main
in repository https://gitbox.apache.org/repos/asf/shardingsphere-on-cloud.git


The following commit(s) were added to refs/heads/main by this push:
     new 4ae5381  Update readme description about agent (#257)
4ae5381 is described below

commit 4ae5381ceff9a1da1df5232bdfb063f62462e1cd
Author: moomman <[email protected]>
AuthorDate: Thu Mar 9 17:26:58 2023 +0800

    Update readme description about agent (#257)
    
    * test push
    
    * back init
    
    * add agent to depolyment and value.yaml
    
    * enable metrics and add agent jar,fix by inject
    
    * Update Helm charts of ShardingSphere Proxy to support metrics agent
    
    * add README description about agent
    
    ---------
    
    Co-authored-by: moonman <[email protected]>
---
 .../apache-shardingsphere-proxy-charts/README.md   | 22 ++++++++++++++++------
 .../templates/configmap.yaml                       |  2 +-
 .../apache-shardingsphere-proxy-charts/values.yaml | 14 ++++++++++++--
 3 files changed, 29 insertions(+), 9 deletions(-)

diff --git a/charts/apache-shardingsphere-proxy-charts/README.md 
b/charts/apache-shardingsphere-proxy-charts/README.md
index d93fada..90d824c 100644
--- a/charts/apache-shardingsphere-proxy-charts/README.md
+++ b/charts/apache-shardingsphere-proxy-charts/README.md
@@ -1,17 +1,22 @@
 # Apache ShardingSphere-Proxy Charts
+
 This Chart is used to quickly install ShardingSphere-Proxy Cluster without 
ShardingSphere-Operator.
 
 ## Install
+
 Use the following command to install:
-```shell
+
+```
 helm repo add shardingsphere https://apache.github.io/shardingsphere-on-cloud
 helm repo update
 helm install [RELEASE_NAME] shardingsphere/apache-shardingsphere-proxy-charts 
--version 0.1.0
 ```
 
 ## Uninstall
+
 Use the following command to uninstall:
-```shell
+
+```
 helm unstall [RELEASE_NAME]
 ```
 
@@ -19,14 +24,16 @@ helm unstall [RELEASE_NAME]
 
 ### Governance-Node parameters
 
+
 | Name                 | Description                                           
| Value  |
-| -------------------- | ----------------------------------------------------- 
| ------ |
+| ---------------------- | 
------------------------------------------------------- | -------- |
 | `governance.enabled` | Switch to enable or disable the governance helm chart 
| `true` |
 
 ### Governance-Node ZooKeeper parameters
 
+
 | Name                                             | Description               
                           | Value               |
-| ------------------------------------------------ | 
---------------------------------------------------- | ------------------- |
+| -------------------------------------------------- | 
------------------------------------------------------ | --------------------- |
 | `governance.zookeeper.enabled`                   | Switch to enable or 
disable the ZooKeeper helm chart | `true`              |
 | `governance.zookeeper.replicaCount`              | Number of ZooKeeper nodes 
                           | `1`                 |
 | `governance.zookeeper.persistence.enabled`       | Enable persistence on 
ZooKeeper using PVC(s)         | `false`             |
@@ -39,8 +46,9 @@ helm unstall [RELEASE_NAME]
 
 ### Compute-Node ShardingSphere-Proxy parameters
 
+
 | Name                                | Description                            
                      | Value                         |
-| ----------------------------------- | 
------------------------------------------------------------ 
|-------------------------------|
+| ------------------------------------- | 
-------------------------------------------------------------- | 
------------------------------- |
 | `compute.image.repository`          | Image name of ShardingSphere-Proxy.    
                      | `apache/shardingsphere-proxy` |
 | `compute.image.pullPolicy`          | The policy for pulling 
ShardingSphere-Proxy image            | `IfNotPresent`                |
 | `compute.image.tag`                 | ShardingSphere-Proxy image tag         
                      | `5.2.0`                       |
@@ -53,4 +61,6 @@ helm unstall [RELEASE_NAME]
 | `compute.service.port`              | ShardingSphere-Proxy expose port       
                      | `3307`                        |
 | `compute.mysqlConnector.version`    | MySQL connector version                
                      | `5.1.49`                      |
 | `compute.startPort`                 | ShardingSphere-Proxy start port        
                      | `3307`                        |
-| `compute.serverConfig`              | Server Configuration file for 
ShardingSphere-Proxy            | `""`                          |
+| `compute.serverConfig`              | Server Configuration file for 
ShardingSphere-Proxy           | `""`                          |
+| `compute.agent.enabled`             | switch to enable or disable the agent 
metrics                | `true`                        |
+| `compute.agent.config`              | agent Configuration file for 
ShardingSphere-Proxy agent      | `""`                          |
diff --git a/charts/apache-shardingsphere-proxy-charts/templates/configmap.yaml 
b/charts/apache-shardingsphere-proxy-charts/templates/configmap.yaml
index 6b191da..ba4324e 100644
--- a/charts/apache-shardingsphere-proxy-charts/templates/configmap.yaml
+++ b/charts/apache-shardingsphere-proxy-charts/templates/configmap.yaml
@@ -64,5 +64,5 @@ metadata:
   name: add-metrics
 data:
   agent.yaml: |-
-    {{- include "common.tplvalues.render" (dict "value" 
.Values.compute.agent.agentConfig "context" $) | nindent 4 }}
+    {{- include "common.tplvalues.render" (dict "value" 
.Values.compute.agent.config "context" $) | nindent 4 }}
     {{- end}}
diff --git a/charts/apache-shardingsphere-proxy-charts/values.yaml 
b/charts/apache-shardingsphere-proxy-charts/values.yaml
index dfcf443..2a4fc8d 100644
--- a/charts/apache-shardingsphere-proxy-charts/values.yaml
+++ b/charts/apache-shardingsphere-proxy-charts/values.yaml
@@ -158,10 +158,20 @@ compute:
     props:
       proxy-frontend-database-protocol-type: MySQL
 
-  ### agent configuration
+  ## @section Compute-Node ShardingSphere-Proxy agent parameters
+  ## @param compute.agent.enabled Switch to enable or disable the agent metrics
   agent:
     enabled: true
-    agentConfig:
+    ## @section Compute-Node ShardingSphere-Proxy agent Configuration 
parameters
+    ## ref: 
https://shardingsphere.apache.org/document/current/en/user-manual/shardingsphere-proxy/observability/
+    ## @param compute.agent.config.plugins list the agent plugins we can use
+    ## @param compute.agent.config.plugins.logging.File Now only build 
metadata time-consuming log output, no other log output.
+    ## @param compute.agent.config.plugins.logging.File.props.level output 
level of logs
+    ## @param compute.agent.config.plugins.metrics.Prometheus Used for 
exposure monitoring indicators
+    ## @param compute.agent.config.plugins.metrics.Prometheus.host host 
address, default localhost
+    ## @param compute.agent.config.plugins.metrics.Prometheus.port 
port,default 9090
+    ## @param 
compute.agent.config.plugins.metrics.Prometheus.props.jvm-information-collector-enabled
 Whether to collect JVM indicator information,default true to enable
+    config:
       plugins:
         logging:
           File:

Reply via email to