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

Set service name for boto3/botocore from env var #9040

Closed
HoneyryderChuck opened this issue Apr 18, 2024 · 5 comments
Closed

Set service name for boto3/botocore from env var #9040

HoneyryderChuck opened this issue Apr 18, 2024 · 5 comments

Comments

@HoneyryderChuck
Copy link

Summary of problem

Several other client libs support service name overrides from env var (DD_AREDIS_SERVICE, DD_PSYCOPG_SERVICE, DD_HTTPX_SERVICE), but there's no such env var support for overriding botocore service name (currently it's "aws.sqs", "aws.s3"...)

In fact, patching

Which version of dd-trace-py are you using?

I've searched on "latest" docs, and found nothing. But I'm using boto3-1.33.13 and botocore-1.33.13.

How can we reproduce your problem?

import ddtrace
ddtrace.config.botocore["service_name"] = "bang"
ddtrace.patch(botocore=True)
# now try sending a message with SQS or smth..

What is the result that you get?

service name was not overridden (still "aws.sqs").

What is the result that you expected?

service name "bang".

@emmettbutler
Copy link
Collaborator

cc @tabgok

@github-actions github-actions bot added the stale label Jun 18, 2024
@joshverma
Copy link

Any update on this?

@quinna-h
Copy link
Contributor

Hi @HoneyryderChuck ,

Thanks for submitting this issue! Could you provide more information as to why you want to override the service name for botocore? Generally the different botocore services have different functionality (between aws.sqs or aws.s3) so we haven't provided a setting for global override.

@HoneyryderChuck
Copy link
Author

Most other integrations allow changing the service name. In the use case of managing multiple services, it makes it easier to narrow down which traces belong to which service.

@github-actions github-actions bot removed the stale label Jul 26, 2024
@quinna-h
Copy link
Contributor

quinna-h commented Jul 29, 2024

Hi @HoneyryderChuck ,

Thanks for raising this issue! We created the fix as part of the latest 2.10.0 release (link)

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

No branches or pull requests

4 participants