Hello team, We are trying to setup our metrics co...
# support
m
Hello team, We are trying to setup our metrics collection and tracing through signoz. We have been following this blog for the setup https://signoz.io/blog/opentelemetry-django/ We are building the Dockerfile provided with the sample-django app using the following compose file.
Copy code
version: "3.8"

services:
  django:
    command: "opentelemetry-instrument gunicorn mysite.wsgi -c gunicorn.config.py --workers 2 --threads 2 --reload --bind 0.0.0.0:8000"
    image: signoz-sample-django:latest
    build:
      context: .
    environment:
      - OTEL_METRICS_EXPORTER=none
      - OTEL_SERVICE_NAME=djangoApp
      - OTEL_EXPORTER_OTLP_ENDPOINT=host.docker.internal:4317
      - DJANGO_SETTINGS_MODULE=mysite.settings
    ports:
      - 8000:8000
The issue that we are facing is that the django service is not recognized by the signoz setup and we are unavailable to get the service shown in our dashboard. Please help us in identifying any issues if any from our end. Also when we went through the source code for the sample django app we saw that you people are using a custom middleware polls.middleware.StatsdMetricsMiddleware upon checking the source code for that middleware we found out that you have instantiated a DogStatsd client (link). Can you also help us in telling what this client is used for as we do not have any service running on this port in our host? Is it a miss in the documentation, if yes please provide the correct way going forward with this.
v
@User
s
@User Your data is probably not reaching the signoz because of n/w issue or something. And regarding the DogStatsd, it is used for sending the request metrics but right now it is not useful as there is no server receiving and processing them.
m
How do i point my sample django app to reach signoz stack? There is a diff between README.md of django app and the signoz blog in general
s
I don't see any major differences b/w them. One is more elaborative and other is simple. Just to confirm were you able to see the service when run normally on machine instead of docker?
And here is the troubleshooting guide that might help https://signoz.io/docs/install/troubleshooting/
m
@User
a
@User
Also when we went through the source code for the sample django app we saw that you people are using a custom middleware polls.middleware.StatsdMetricsMiddleware upon checking the source code for that middleware we found out that you have instantiated a DogStatsd client
I don't think this middleware is needed. It was just to test statsd ingestion to signoz. But let us verify and confirm.