[Java] Extract common timestamp output DoFn - #40077
Conversation
Signed-off-by: xujiantop-crypto <265865031+xujiantop-crypto@users.noreply.github.com>
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## master #40077 +/- ##
============================================
- Coverage 58.52% 57.24% -1.28%
+ Complexity 5980 3695 -2285
============================================
Files 1459 1200 -259
Lines 208448 194031 -14417
Branches 5364 3889 -1475
============================================
- Hits 121985 111070 -10915
+ Misses 82166 79362 -2804
+ Partials 4297 3599 -698
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
|
Assigning reviewers: R: @kennknowles for label java. This pull request likely touches a core component ("core" label). Please review with scrutiny. 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). |
|
Hello! Thanks for contributing! I'm sorry we left that GitHub issue open. I don't actually think we should do this, for two reasons:
|
Extract a package-private
OutputWithTimestampDoFnshared byWithTimestamps.AddTimestampsDoFnandCreate.TimestampedValues.ConvertTimestamps.The existing transform structure is intentionally preserved. In particular,
Create.TimestampedValuesstill creates an intermediatePCollection<TimestampedValue<T>>, usesTimestampedValueCoder, restores theoutput coder, and retains the
ConvertTimestampstransform name. This avoidsthe runner matching issue that previously occurred when
TimestampedValuesinherited fromCreate.Values.WithTimestampscontinues to preserve its null timestamp validation andallowed timestamp skew behavior.
Tests:
:sdks:java:core:testforWithTimestampsTestandCreateTest:runners:direct-java:needsRunnerTestforWithTimestampsTestandCreateTest:sdks:java:core:spotlessJavaCheck:sdks:java:core:javadocFixes #18350