-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat:support inject java agent to user pod (#163)
- Loading branch information
1 parent
4485468
commit 9d7e5dc
Showing
19 changed files
with
1,603 additions
and
294 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
107 changes: 107 additions & 0 deletions
107
deploy/kubernetes_v1.21/helm/templates/controller-configmap-javaagent.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: plugin-default.properties | ||
namespace: polaris-system | ||
labels: | ||
app: sidecar-injector | ||
data: | ||
springcloud2020-default-properties: |+ | ||
# 应用名称 | ||
spring.application.name={{ .MicroserviceName }} | ||
# 配置北极星服务端地址 | ||
spring.cloud.polaris.address=grpc\://{{ .PolarisServerIP }}\:{{ .PolarisDiscoverPort }} | ||
spring.cloud.polaris.enabled=true | ||
# 启用 Java Agent 的 Spring Cloud Tencent 注册发现能力 | ||
spring.cloud.discovery.enabled=true | ||
# 配置服务注册发现的命名空间信息 | ||
spring.cloud.polaris.discovery.namespace=default | ||
# 启用从北极星 | ||
spring.cloud.polaris.discovery.enabled=true | ||
spring.cloud.polaris.discovery.register=true | ||
## 是否启用北极星的 LoadBalancer | ||
spring.cloud.polaris.loadbalancer.enabled=true | ||
#spring.cloud.polaris.loadbalancer.discoveryType=POLARIS | ||
#spring.cloud.polaris.loadbalancer.strategy=random | ||
## 是否启用北极星服务路由能力 | ||
spring.cloud.polaris.router.enabled=false | ||
# 是否启用北极星的自定义路由能力 | ||
spring.cloud.polaris.router.rule-router.enabled=false | ||
# 是否启用北极星的元数据路由能力 | ||
spring.cloud.polaris.router.metadata-router.enabled=false | ||
# 是否启用北极星的就近路由能力 | ||
spring.cloud.polaris.router.nearby-router.enabled=false | ||
## 是否启用北极星的服务限流能力 | ||
spring.cloud.polaris.ratelimit.enabled=false | ||
# 设置触发限流时的提示信息 | ||
# spring.cloud.polaris.ratelimit.rejectRequestTips="" | ||
# 设置触发限流时的响应码 | ||
spring.cloud.polaris.ratelimit.rejectHttpCode=429 | ||
# 设置限流匀速排队最大排队时间 | ||
spring.cloud.polaris.ratelimit.maxQueuingTime=1000 | ||
## RPC 调用增强 | ||
spring.cloud.tencent.rpc-enhancement.enabled=false | ||
# 开启 RPC 调用结果上报 | ||
spring.cloud.tencent.rpc-enhancement.reporter.enabled=false | ||
# 配置北极星监控指标上报 | ||
spring.cloud.polaris.stat.enabled=false | ||
# 指标上报监听端口 | ||
spring.cloud.polaris.stat.port=0 | ||
# 指标上报暴露的 http path | ||
spring.cloud.polaris.stat.path=/metrics | ||
springcloud2021-default-properties: |+ | ||
# 应用名称 | ||
spring.application.name={{ .MicroserviceName }} | ||
# 配置北极星服务端地址 | ||
spring.cloud.polaris.address=grpc\://{{ .PolarisServerIP }}\:{{ .PolarisDiscoverPort }} | ||
spring.cloud.polaris.enabled=true | ||
# 启用 Java Agent 的 Spring Cloud Tencent 注册发现能力 | ||
spring.cloud.discovery.enabled=true | ||
# 配置服务注册发现的命名空间信息 | ||
spring.cloud.polaris.discovery.namespace=default | ||
# 启用从北极星 | ||
spring.cloud.polaris.discovery.enabled=true | ||
spring.cloud.polaris.discovery.register=true | ||
## 是否启用北极星的 LoadBalancer | ||
spring.cloud.polaris.loadbalancer.enabled=true | ||
#spring.cloud.polaris.loadbalancer.discoveryType=POLARIS | ||
#spring.cloud.polaris.loadbalancer.strategy=random | ||
## 是否启用北极星服务路由能力 | ||
spring.cloud.polaris.router.enabled=false | ||
# 是否启用北极星的自定义路由能力 | ||
spring.cloud.polaris.router.rule-router.enabled=false | ||
# 是否启用北极星的元数据路由能力 | ||
spring.cloud.polaris.router.metadata-router.enabled=false | ||
# 是否启用北极星的就近路由能力 | ||
spring.cloud.polaris.router.nearby-router.enabled=false | ||
## 是否启用北极星的服务限流能力 | ||
spring.cloud.polaris.ratelimit.enabled=false | ||
# 设置触发限流时的提示信息 | ||
# spring.cloud.polaris.ratelimit.rejectRequestTips="" | ||
# 设置触发限流时的响应码 | ||
spring.cloud.polaris.ratelimit.rejectHttpCode=429 | ||
# 设置限流匀速排队最大排队时间 | ||
spring.cloud.polaris.ratelimit.maxQueuingTime=1000 | ||
## RPC 调用增强 | ||
spring.cloud.tencent.rpc-enhancement.enabled=false | ||
# 开启 RPC 调用结果上报 | ||
spring.cloud.tencent.rpc-enhancement.reporter.enabled=false | ||
# 配置北极星监控指标上报 | ||
spring.cloud.polaris.stat.enabled=false | ||
# 指标上报监听端口 | ||
spring.cloud.polaris.stat.port=0 | ||
# 指标上报暴露的 http path | ||
spring.cloud.polaris.stat.path=/metrics |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
107 changes: 107 additions & 0 deletions
107
deploy/kubernetes_v1.21/kubernetes/javaagent-configmap.yaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,107 @@ | ||
apiVersion: v1 | ||
kind: ConfigMap | ||
metadata: | ||
name: plugin-default.properties | ||
namespace: polaris-system | ||
labels: | ||
app: sidecar-injector | ||
data: | ||
springcloud2020-default-properties: |+ | ||
# 应用名称 | ||
spring.application.name={{ .MicroserviceName }} | ||
# 配置北极星服务端地址 | ||
spring.cloud.polaris.address=grpc\://{{ .PolarisServerIP }}\:{{ .PolarisDiscoverPort }} | ||
spring.cloud.polaris.enabled=true | ||
# 启用 Java Agent 的 Spring Cloud Tencent 注册发现能力 | ||
spring.cloud.discovery.enabled=true | ||
# 配置服务注册发现的命名空间信息 | ||
spring.cloud.polaris.discovery.namespace=default | ||
# 启用从北极星 | ||
spring.cloud.polaris.discovery.enabled=true | ||
spring.cloud.polaris.discovery.register=true | ||
## 是否启用北极星的 LoadBalancer | ||
spring.cloud.polaris.loadbalancer.enabled=true | ||
#spring.cloud.polaris.loadbalancer.discoveryType=POLARIS | ||
#spring.cloud.polaris.loadbalancer.strategy=random | ||
## 是否启用北极星服务路由能力 | ||
spring.cloud.polaris.router.enabled=false | ||
# 是否启用北极星的自定义路由能力 | ||
spring.cloud.polaris.router.rule-router.enabled=false | ||
# 是否启用北极星的元数据路由能力 | ||
spring.cloud.polaris.router.metadata-router.enabled=false | ||
# 是否启用北极星的就近路由能力 | ||
spring.cloud.polaris.router.nearby-router.enabled=false | ||
## 是否启用北极星的服务限流能力 | ||
spring.cloud.polaris.ratelimit.enabled=false | ||
# 设置触发限流时的提示信息 | ||
# spring.cloud.polaris.ratelimit.rejectRequestTips="" | ||
# 设置触发限流时的响应码 | ||
spring.cloud.polaris.ratelimit.rejectHttpCode=429 | ||
# 设置限流匀速排队最大排队时间 | ||
spring.cloud.polaris.ratelimit.maxQueuingTime=1000 | ||
## RPC 调用增强 | ||
spring.cloud.tencent.rpc-enhancement.enabled=false | ||
# 开启 RPC 调用结果上报 | ||
spring.cloud.tencent.rpc-enhancement.reporter.enabled=false | ||
# 配置北极星监控指标上报 | ||
spring.cloud.polaris.stat.enabled=false | ||
# 指标上报监听端口 | ||
spring.cloud.polaris.stat.port=0 | ||
# 指标上报暴露的 http path | ||
spring.cloud.polaris.stat.path=/metrics | ||
springcloud2021-default-properties: |+ | ||
# 应用名称 | ||
spring.application.name={{ .MicroserviceName }} | ||
# 配置北极星服务端地址 | ||
spring.cloud.polaris.address=grpc\://{{ .PolarisServerIP }}\:{{ .PolarisDiscoverPort }} | ||
spring.cloud.polaris.enabled=true | ||
# 启用 Java Agent 的 Spring Cloud Tencent 注册发现能力 | ||
spring.cloud.discovery.enabled=true | ||
# 配置服务注册发现的命名空间信息 | ||
spring.cloud.polaris.discovery.namespace=default | ||
# 启用从北极星 | ||
spring.cloud.polaris.discovery.enabled=true | ||
spring.cloud.polaris.discovery.register=true | ||
## 是否启用北极星的 LoadBalancer | ||
spring.cloud.polaris.loadbalancer.enabled=true | ||
#spring.cloud.polaris.loadbalancer.discoveryType=POLARIS | ||
#spring.cloud.polaris.loadbalancer.strategy=random | ||
## 是否启用北极星服务路由能力 | ||
spring.cloud.polaris.router.enabled=false | ||
# 是否启用北极星的自定义路由能力 | ||
spring.cloud.polaris.router.rule-router.enabled=false | ||
# 是否启用北极星的元数据路由能力 | ||
spring.cloud.polaris.router.metadata-router.enabled=false | ||
# 是否启用北极星的就近路由能力 | ||
spring.cloud.polaris.router.nearby-router.enabled=false | ||
## 是否启用北极星的服务限流能力 | ||
spring.cloud.polaris.ratelimit.enabled=false | ||
# 设置触发限流时的提示信息 | ||
# spring.cloud.polaris.ratelimit.rejectRequestTips="" | ||
# 设置触发限流时的响应码 | ||
spring.cloud.polaris.ratelimit.rejectHttpCode=429 | ||
# 设置限流匀速排队最大排队时间 | ||
spring.cloud.polaris.ratelimit.maxQueuingTime=1000 | ||
## RPC 调用增强 | ||
spring.cloud.tencent.rpc-enhancement.enabled=false | ||
# 开启 RPC 调用结果上报 | ||
spring.cloud.tencent.rpc-enhancement.reporter.enabled=false | ||
# 配置北极星监控指标上报 | ||
spring.cloud.polaris.stat.enabled=false | ||
# 指标上报监听端口 | ||
spring.cloud.polaris.stat.port=0 | ||
# 指标上报暴露的 http path | ||
spring.cloud.polaris.stat.path=/metrics |
Oops, something went wrong.