#support

Issues with Logger Addition in Python FastAPI Based Services

TLDR Sahil is struggling to push server logs to the signoz dashboard and wants to remove signoz logs. Srikanth suggested enabling auto instrumentation but it didn't resolve the issue.

Powered by Struct AI
Jul 25, 2023 (2 months ago)
Sahil
Photo of md5-0d29f9c842118cfaa4357530db1a6924
Sahil
12:47 PM
I am trying to add logger for my python fastAPI base services.

I am able to see the exceptions and trace. But when I click on Go to related logs I am not getting any logs.
All the logs in the logs tab seem to be internal signoz logs or click house logs.

How can I make it such that all the server logs are pushed and shown in the signoz dashboard.

All I have done is this
pip install opentelemetry-distro
pip install opentelemetry-exporter-otlp
opentelemetry-bootstrap --action=install
export OTEL_RESOURCE_ATTRIBUTES=service.name=fastapiApp
export OTEL_EXPORTER_OTLP_ENDPOINT=""
opentelemetry-instrument uvicorn main:app --host localhost --port 5002
Jul 26, 2023 (2 months ago)
Srikanth
Photo of md5-ce04a9988e2fd758a659dc55be6f2543
Srikanth
06:32 AM
Set OTEL_PYTHON_LOGGING_AUTO_INSTRUMENTATION_ENABLED to true
Sahil
Photo of md5-0d29f9c842118cfaa4357530db1a6924
Sahil
07:09 AM
still doesn't work.
2. How do I remove signoz logs. I only want my service logs.