-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[receiver/sqlqueryreceiver] Fix tracking results by timestamp column #35195
[receiver/sqlqueryreceiver] Fix tracking results by timestamp column #35195
Conversation
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.
One minor nit, but it looks good. Thanks for making this change!
@crobert-1 |
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.
Thank you for this fix @Grandys.
I'm only worried that we don't have test coverage for logs tracking for database engines other than PostgreSQL. This means that we're treading in the dark with this feature and changes to it like this valuable fix. As a result, there's a risk that this fix breaks the logs tracking feature for one of the untested engines (e.g. because the RFC3939Nano format is not supported).
I'm supportive of merging this fix, given that the logs stability is currently development
. We should have integrations tests for all supported database engines before we move logs support out of development
into alpha
stability or further.
4c6d6a5
into
open-telemetry:main
…pen-telemetry#35195) **Description:** Formats retrieved time columns with milliseconds precision, so they are not reprocessed when used as a tracking_column **Link to tracking Issue:** open-telemetry#35194 **Testing:** Added integration test, updated test data **Documentation:** n/a Closes open-telemetry#35194
…36922) <!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Mainly added test for sqlserver, plus added coverage for logs (as requested in [comment](#35195 (review))) <!-- Issue number (e.g. #1234) or full URL to issue, if applicable. --> #### Link to tracking issue Fixes #29695 <!--Describe what testing was performed and which tests were added.--> #### Testing Main changes: * Added metrics tests for SqlServer * Covered MySql, SqlServer and Oracle for logs Improvements: - To avoid repetitions, changed approach to "parameterized" tests - run the same test flow for different database engines (for logs only). - Do not hardcode "localhost" and host port, get these values from testcontainers. - Replaced inserting test values into the database from running CLI commands in the container to executing SQL commands. - Updated Oracle init script to use `otel` schema instead of `sys`. Important: For Oracle and SQL Server, tests are **skipped** (tested locally) - I expect them to fail due to #27577 (which was not fixed but closed due to inactivity). <!--Describe the documentation added.--> <!--Please delete paragraphs that you did not use before submitting.-->
…pen-telemetry#36922) <!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Mainly added test for sqlserver, plus added coverage for logs (as requested in [comment](open-telemetry#35195 (review))) <!-- Issue number (e.g. open-telemetry#1234) or full URL to issue, if applicable. --> #### Link to tracking issue Fixes open-telemetry#29695 <!--Describe what testing was performed and which tests were added.--> #### Testing Main changes: * Added metrics tests for SqlServer * Covered MySql, SqlServer and Oracle for logs Improvements: - To avoid repetitions, changed approach to "parameterized" tests - run the same test flow for different database engines (for logs only). - Do not hardcode "localhost" and host port, get these values from testcontainers. - Replaced inserting test values into the database from running CLI commands in the container to executing SQL commands. - Updated Oracle init script to use `otel` schema instead of `sys`. Important: For Oracle and SQL Server, tests are **skipped** (tested locally) - I expect them to fail due to open-telemetry#27577 (which was not fixed but closed due to inactivity). <!--Describe the documentation added.--> <!--Please delete paragraphs that you did not use before submitting.-->
Description:
Formats retrieved time columns with milliseconds precision, so they are not reprocessed when used as a tracking_column
Link to tracking Issue: #35194
Testing: Added integration test, updated test data
Documentation: n/a
Closes #35194