Repository navigation
Conversation
There was a problem hiding this comment.
📋 Review Summary
This PR resolves a test data collision issue in GenerateData where random timestamps truncated to millisecond precision could collide for the same measurement, causing InfluxDB to merge points and fail count assertions in InfluxDbIOIT. The fix cleanly tracks per-measurement timestamps, increments on collision, and removes code duplication between getMetric and getMultipleMetric.
🔍 General Feedback
- The implementation is clean, concise, and properly scopes timestamp deduplication per measurement (even if duplicate measurement names are passed to
getMultipleMetric). - Eliminating the duplicated point generation loop in
getMultipleMetricimproves maintainability.
💡 Tip: Comment /gemini review on this pull request to trigger a new Gemini code review.
|
Assigning reviewers: R: @chamikaramj for label java. Note: If you would like to opt out of this review, comment Available commands:
The PR bot will only process comments in the main thread (not review comments). |
Related #26866.
The fixture generates nanosecond timestamps but writes with millisecond precision. Points for the same measurement can land on the same millisecond, and InfluxDB merges them. Preserve the random timestamps while advancing collisions, and use the same generator for multi-metric data.
Reproduced the missing-point failure in the existing integration test against InfluxDB 1.8, then reran it successfully with the fix. The full integration class, module tests, and formatting checks also passed. The local module checks can be run with
./gradlew :sdks:java:io:influxdb:test :sdks:java:io:influxdb:spotlessJavaCheck.