Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Introduce config variables samplingRate & statsSocketPath #512

Merged
merged 17 commits into from
Sep 22, 2021

Conversation

suniltheta
Copy link
Contributor

From v1.19.1.0-prod AppMesh Envoy image release we support two new env variables on Envoy proxy container.

  1. XRAY_SAMPLING_RATE
  2. STATSD_SOCKET_PATH Feature Request: DogStatsD UDS Support aws-app-mesh-roadmap#342

See docs: https://docs.aws.amazon.com/app-mesh/latest/userguide/envoy-config.html

This change will expose those env variable via helm configuration variable.

By submitting this pull request, I confirm that you can use, modify, copy, and redistribute this contribution, under the terms of your choice.

@suniltheta suniltheta marked this pull request as ready for review September 8, 2021 21:30
@suniltheta suniltheta requested a review from cgchinmay September 8, 2021 21:32
config/helm/appmesh-controller/values.yaml Outdated Show resolved Hide resolved
pkg/inject/config.go Show resolved Hide resolved
Copy link
Contributor

@cgchinmay cgchinmay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added my comments

config/helm/appmesh-controller/README.md Outdated Show resolved Hide resolved
config/helm/appmesh-controller/README.md Show resolved Hide resolved
Copy link
Contributor

@cgchinmay cgchinmay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Awaiting testing results for this change

@suniltheta
Copy link
Contributor Author

Envoy yaml config that is generated when setting

helm upgrade -i appmesh-controller eks/appmesh-controller --namespace appmesh-system --set sidecar.image.repository=840364872350.dkr.ecr.us-west-2.amazonaws.com/aws-appmesh-envoy --set sidecar.image.tag=v1.19.1.0-prod --set image.repository=894069144441.dkr.ecr.us-west-2.amazonaws.com/amazon/appmesh-controller --set image.tag=v1.4.2 --set tracing.samplingRate=0.01 --set stats.statsdSocketPath=/dev/null --set stats.statsdEnabled=true
---
statsSinks:
- name: envoy.stat_sinks.dog_statsd
 typedConfig:
   '@type': type.googleapis.com/envoy.config.metrics.v3.DogStatsdSink
   address:
     pipe:
       path: /dev/null
tracing:
 http:
   name: envoy.tracers.xray
   typedConfig:
     '@type': type.googleapis.com/envoy.config.trace.v3.XRayConfig
     daemonEndpoint:
       address: 127.0.0.1
       portValue: 2000
       protocol: UDP
     samplingRuleManifest:
       filename: /tmp/sampling-rules.json
     segmentFields:
       aws:
         app_mesh:
           mesh_name: howto-k8s-http2
           virtual_node_name: client_howto-k8s-http2
       origin: AWS::AppMesh::Proxy
     segmentName: howto-k8s-http2/client_howto-k8s-http2

========================================================================

Contents of /tmp/sampling-rules.json

bash-4.2$ cat /tmp/sampling-rules.json 
{"version":2,"default":{"service_name":"","host":"","http_method":"","url_path":"","fixed_target":1,"rate":0.01},"rules":[]}bash-4.2$ 

Copy link
Contributor

@cgchinmay cgchinmay left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added comment for default value of xRay sampling rate. Rest looks good

config/helm/appmesh-controller/values.yaml Outdated Show resolved Hide resolved
@cgchinmay cgchinmay merged commit e2b5e25 into aws:master Sep 22, 2021
cgchinmay pushed a commit to cgchinmay/aws-app-mesh-controller-for-k8s that referenced this pull request Nov 19, 2021
Xray SamplingRate changes

Add service instance port to Cloud Map Service Discovery (aws#490)

Volume injection support (aws#488)

Introduce config variables for samplingRate & statsSocketPath (aws#512)

Use xray daemon from ecr public repo instead of dockerhub

update envoy image to 1.19.1.1-prod

Updated proxy-route-manager to v4-prod

Updated Dockerfile to support multi-arch
Updated Makefile to use docker buildx

Updated go version
cgchinmay pushed a commit to cgchinmay/aws-app-mesh-controller-for-k8s that referenced this pull request Nov 19, 2021
Xray SamplingRate changes

Add service instance port to Cloud Map Service Discovery (aws#490)

Volume injection support (aws#488)

Introduce config variables for samplingRate & statsSocketPath (aws#512)

Use xray daemon from ecr public repo instead of dockerhub

update envoy image to 1.19.1.1-prod

Updated proxy-route-manager to v4-prod

Updated Dockerfile to support multi-arch
Updated Makefile to use docker buildx

Updated go version

Updated spire agent and server to 0.12.0 to be compatible with envoy v1.19.x

Dockerfile changes to support ARM
cgchinmay pushed a commit to cgchinmay/aws-app-mesh-controller-for-k8s that referenced this pull request Nov 29, 2021
Xray SamplingRate changes

Add service instance port to Cloud Map Service Discovery (aws#490)

Volume injection support (aws#488)

Introduce config variables for samplingRate & statsSocketPath (aws#512)

Use xray daemon from ecr public repo instead of dockerhub

update envoy image to 1.19.1.1-prod

Updated proxy-route-manager to v4-prod

Updated Dockerfile to support multi-arch
Updated Makefile to use docker buildx

Updated go version

Updated spire agent and server to 0.12.0 to be compatible with envoy v1.19.x

Dockerfile changes to support ARM

Bump Envoy image version to v1.20.0.1-prod (aws#538)

Co-authored-by: Shailesh Gupta <[email protected]>
cgchinmay pushed a commit that referenced this pull request Dec 2, 2021
Xray SamplingRate changes

Add service instance port to Cloud Map Service Discovery (#490)

Volume injection support (#488)

Introduce config variables for samplingRate & statsSocketPath (#512)

Use xray daemon from ecr public repo instead of dockerhub

Updated proxy-route-manager to v4-prod

Updated Dockerfile to support multi-arch
Updated Makefile to use docker buildx

Updated go version

Updated spire agent and server to 0.12.0 to be compatible with envoy v1.19.x

Dockerfile changes to support ARM

Bump Envoy image version to v1.20.0.1-prod (#538)

Co-authored-by: Shailesh Gupta <[email protected]>

Update Chart and App version for new patch release
cgchinmay pushed a commit that referenced this pull request Mar 24, 2022
* Fixes for v1.4.1 patch release

reverts default envoy image version to 1.16 (#494)

Used EKS-D minimal non root as the base image instead of amazonlinux:2 (#501)

Co-authored-by: Chinmay Gadgil <[email protected]>

Use root image of minimal EKD-D to read service account token (#502)

Fix for failing UT

Updating unit-test.yml file to fix kubebuilder issue

Co-authored-by: Chinmay Gadgil <[email protected]>

Remove field length constraints from query parameter exact match criteria (#487)

Updated Chart minor version

Updated CRD field constraints for queryparameters

Co-authored-by: Chinmay Gadgil <[email protected]>

HTTPQueryParam CRD Description update

CRD QueryParameter description update

Update helm to use v1.4.1 of the appmesh-controller

helm update

* Updated eks-distro-minimal-base image (#527)

Xray SamplingRate changes

Add service instance port to Cloud Map Service Discovery (#490)

Volume injection support (#488)

Introduce config variables for samplingRate & statsSocketPath (#512)

Use xray daemon from ecr public repo instead of dockerhub

Updated proxy-route-manager to v4-prod

Updated Dockerfile to support multi-arch
Updated Makefile to use docker buildx

Updated go version

Updated spire agent and server to 0.12.0 to be compatible with envoy v1.19.x

Dockerfile changes to support ARM

Bump Envoy image version to v1.20.0.1-prod (#538)

Co-authored-by: Shailesh Gupta <[email protected]>

Update Chart and App version for new patch release

* Update api extensions to v1

* Add preserveUnknownFields to CRDs

* Bump CRD patches to apiextensions v1

* Fix CRDs to match release-1.4

* Revert "Fix CRDs to match release-1.4"

This reverts commit 7e3c58f.

Co-authored-by: Rex Chang <[email protected]>
Co-authored-by: cgchinmay <[email protected]>
Co-authored-by: Sebastien Allamand <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants