GithubHelp home page GithubHelp logo

k8sattributes-repro's Introduction

Instructions to reproduce

Using opentelemetry collector 0.54.0

On a machine with docker already installed:

  1. brew install kind kubernetes-cli helm
  2. kind create cluster --config kind-1worker-config.yaml
  3. kubectl config use-context kind-kind
  4. helm repo add open-telemetry https://open-telemetry.github.io/opentelemetry-helm-charts
  5. helm install my-otel-demo open-telemetry/opentelemetry-demo
  6. helm install --values values.agent.yaml agent open-telemetry/opentelemetry-collector
  7. helm install --values values.gateway.yaml gateway open-telemetry/opentelemetry-collector
  8. kubectl patch deployment/my-otel-demo-frontend --type json --patch-file patch-my-otel-demo-1.yaml
  9. kubectl set env deployment/my-otel-demo-frontend OTEL_EXPORTER_OTLP_ENDPOINT='http://$(K8S_NODE_IP):4317
  10. kubectl port-forward svc/my-otel-demo-frontend 8080:8080
  11. kubectl logs -f deployment/gateway-opentelemetry-collector
  • Note: You may need to wait a while before step 9 to ensure all of the my-otel-demo deployments have succeeded.

  • Go to your browser and access http://localhost:8080

  • Watch for the traces coming in, and note that the debug logs from k8sattributesprocessor indicates that it has matched the pod IP from k8s.pod.ip and is adding the requested attributes to the resource associated with the traces.

Using opentelemetry collector 0.55.0

  • Edit values.gateway.yaml and replace image.tag by "0.55.0"
  • Run helm upgrade gateway --values values.gateway.yaml open-telemetry/opentelemetry-collector
  • Run the same kubectl logs -f deployment/gateway-opentelemetry-collector and now note that the k8sattributesprocessor can no longer match the incoming pod IP specified in k8s.pod.ip

k8sattributes-repro's People

Contributors

evantorrie avatar

Watchers

 avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.