-
Notifications
You must be signed in to change notification settings - Fork 467
feat(profiling): remove stack v1 #15185
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
Conversation
This change removes the `cassandra` contrib package, which is only tested on the to-be-removed Python 3.8 runtime.
## Motivation The mongoengine integration does not generate any spans and only supports attaching a Pin object to the underlying pymongo client. Since we're deprecating the Pin mechanism and pymongo already fully supports the needed functionality, maintaining the mongoengine integration is redundant. ## Description This PR removes the mongoengine integration from ddtrace. The pymongo integration, which is enabled by default, will continue to provide tracing for applications using mongoengine, as mongoengine internally uses pymongo. The only notable change is that users can no longer set a Pin on the mongoengine client. Instead, they should configure the Pin directly on the pymongo client if needed. Support for the Pin API will be removed in a future release. ## Checklist - [x] PR author has checked that all the criteria below are met - The PR description includes an overview of the change - The PR description articulates the motivation for the change - The change includes tests OR the PR description describes a testing strategy - The PR description notes risks associated with the change, if any - Newly-added code is easy to change - The change follows the [library release note guidelines](https://ddtrace.readthedocs.io/en/stable/releasenotes.html) - The change includes or references documentation updates if necessary - Backport labels are set (if [applicable](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)) ## Reviewer Checklist - [ ] Reviewer has checked that all the criteria below are met - Title is accurate - All changes are related to the pull request's stated goal - Avoids breaking [API](https://ddtrace.readthedocs.io/en/stable/versioning.html#interfaces) changes - Testing strategy adequately addresses listed risks - Newly-added code is easy to change - Release note makes sense to a user of the library - If necessary, author has acknowledged and discussed the performance implications of this PR as reported in the benchmarks PR comment - Backport labels are set in a manner that is consistent with the [release branch maintenance policy](https://ddtrace.readthedocs.io/en/latest/contributing.html#backporting)
This change removes the deprecated `opentracer` package from ddtrace. Note the base branch, a staging area for breaking changes slated for 4.0. --------- Co-authored-by: brettlangdon <[email protected]>
This change removes deprecated methods and method parameters from the `Span` class. Note the base branch, a staging area for breaking changes slated for 4.0. --------- Co-authored-by: brettlangdon <[email protected]>
This change removes support and testing for Python 3.8, which reached its end-of-life in late 2024 and was deprecated in ddtrace in #14890. It also deprecates support for Python 3.9, which reached its end-of-life recently. This includes removal of the `cassandra` integration, which is only tested under Python 3.8. Note that the base branch is not `main`, but a branch on which we can stage the breaking changes for the 4.0 release. Depends on DataDog/system-tests#5547 --------- Co-authored-by: Sam Brenner <[email protected]> Co-authored-by: Gabriele N. Tornetta <[email protected]>
This change removes the deprecated `freezegun` integration from ddtrace. Note the base branch, a staging area for breaking changes slated for 4.0. --------- Co-authored-by: Vlad Scherbich <[email protected]> Co-authored-by: Taegyun Kim <[email protected]>
This change removes the deprecated functionality that controls ingestion via analytics. Note the base branch, a staging area for breaking changes slated for 4.0.
This change replaces `ddtrace.settings` with `ddtrace.internal.settings` because we've decided to disallow settings adjustment via code, preferring environment variable configuration. Note the base branch, a staging area for breaking changes slated for 4.0.
This change removes deprecated attributes from the `ddtrace.trace` and `ddtrace._trace` modules. Note the base branch, a staging area for breaking changes slated for 4.0. --------- Co-authored-by: Brett Langdon <[email protected]>
## Description [MLOB-4128] Drops the optional tiktoken dependency from ddtrace. Also removes tiktoken estimation of tokens from the openai integration. This was only used by customers that explicitly rejected streamed token metrics from streamed chat/responses, which is an extreme minority of users. We made the call that this optional dependency wasn't worth the maintenance burden (difficulty in updating python versions, other third party libraries, etc) in our ddtrace 4.0 major release. We'll just default to estimating the token count with our super simple heuristic if token counts are not provided by openai. This PR also updates testing to test openai==2.2.0. <!-- Provide an overview of the change and motivation for the change --> ## Testing <!-- Describe your testing strategy or note what tests are included --> ## Risks <!-- Note any risks associated with this change, or "None" if no risks --> ## Additional Notes <!-- Any other information that would be helpful for reviewers --> [MLOB-4128]: https://datadoghq.atlassian.net/browse/MLOB-4128?atlOrigin=eyJpIjoiNWRkNTljNzYxNjVmNDY3MDlhMDU5Y2ZhYzA5YTRkZjUiLCJwIjoiZ2l0aHViLWNvbS1KU1cifQ
| ], | ||
| ), | ||
| Venv( | ||
| name="profile-diff", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@P403n1x87 don't think this venv is used anywhere. Deleting.
|
Is there a plan to rename the remaining |
|
I'm concerned with the size of this diff: 2.6K lines added, 6K lines removed. I think we should break this up into several PRs. Example suggestion: |
If this is not required for the stack v1 removal, I would make this a separate PR. Sounds like a major improvement that will benefit from extra visibility. |
…stors (#15212) ## Description Deprecated in 3.x, now removed in 4.0 ## Testing <!-- Describe your testing strategy or note what tests are included --> ## Risks <!-- Note any risks associated with this change, or "None" if no risks --> ## Additional Notes <!-- Any other information that would be helpful for reviewers --> Co-authored-by: Emmett Butler <[email protected]>
The removal of stack v1 is done mostly in a single PR as the deadline to make changes to 4.0-breaking-changes is today, and @brettlangdon requested me to remove the code as part of 4.0 release. I initially thought of removing them after 4.0 was released as now it can't be enabled unless someone modifies the code to do so. |
) ## Description This is mainly to make sure that `DD_PROFILING_STACK_V2_ENABLED` does nothing. Actual code removal will be followed up in #15185 ## Testing <!-- Describe your testing strategy or note what tests are included --> ## Risks <!-- Note any risks associated with this change, or "None" if no risks --> ## Additional Notes <!-- Any other information that would be helpful for reviewers -->
All the So, basically, are we keeping any |
|
Closing in favor of #15237 |
Description
Remove Python Profiler v1 implementation, and clean up test suites.
One of the notable improvements from this PR is that
StackCollectorno longer spawns an extra background thread by inheriting fromCollectorinstead ofPeriodicService. Also, ddtrace/profiling/collector/stack.pyx has been de-cythonized as it now is a simple wrapper aroundstack_v2native extension module.Testing
Risks
Additional Notes