-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
DATE_TIME should work as the primary time column for Pinot tables #5399
Conversation
Codecov Report
@@ Coverage Diff @@
## master #5399 +/- ##
==========================================
+ Coverage 66.81% 66.84% +0.03%
==========================================
Files 1091 1091
Lines 55783 55782 -1
Branches 8365 8363 -2
==========================================
+ Hits 37273 37290 +17
+ Misses 15762 15744 -18
Partials 2748 2748
Continue to review full report at Codecov.
|
...oker/src/test/java/org/apache/pinot/broker/routing/timeboundary/TimeBoundaryManagerTest.java
Outdated
Show resolved
Hide resolved
...t-broker/src/main/java/org/apache/pinot/broker/routing/timeboundary/TimeBoundaryManager.java
Show resolved
Hide resolved
pinot-core/src/main/java/org/apache/pinot/core/data/function/FunctionEvaluatorFactory.java
Outdated
Show resolved
Hide resolved
you have mentioned that you tested schema with no time on hybrid tables. How does that work for query routing? |
updated comment |
pinot-spi/src/main/java/org/apache/pinot/spi/data/TimeFieldSpec.java
Outdated
Show resolved
Hide resolved
9cc0d14
to
118b8ba
Compare
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.
LGTM. @Jackie-Jiang, @mcvsubbu please look into this
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.
LGTM otherwise
...re/src/main/java/org/apache/pinot/core/segment/creator/impl/SegmentColumnarIndexCreator.java
Outdated
Show resolved
Hide resolved
...re/src/main/java/org/apache/pinot/core/segment/creator/impl/SegmentColumnarIndexCreator.java
Outdated
Show resolved
Hide resolved
...ore/src/main/java/org/apache/pinot/core/segment/name/NormalizedDateSegmentNameGenerator.java
Outdated
Show resolved
Hide resolved
e0dacf8
to
237ca45
Compare
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.
looks ok to me other than minor comment.
pinot-core/src/main/java/org/apache/pinot/core/segment/creator/impl/V1Constants.java
Outdated
Show resolved
Hide resolved
If you can please do these steps to test it
Ideally, do the tests after upgrade controller, and then again after upgrading broker, and then after upgrading server |
Just completed the following test. It all looks green. Initial setup:
Controller upgrade:
Broker upgrade:
Server upgrade:
|
237ca45
to
2726b6a
Compare
Really appreciate your diligence @npawar thanks |
#2756
This PR ensures that Pinot can use a DateTimeFieldSpec as a primary time column for the table.
After this change, we no longer need to use TimeFieldSpec. TimeFieldSpec, TimeGranularitySpec have been marked as Deprecated.
Some tests have been modified to test both cases, some have been changed to use datetime, and some retain time.
Manually tested creating segments, querying and retention for
Some changes
segment.time.column.name
property in the segment metadata is now used to keep primary time column. This will match with the time column name in tableConfig. This can be either timeFieldSpec or dateTimeFieldSpec.If the primary time column is dateTimeFieldSpecs, the segment metadata will look like this
E.g: schema has dimensions
d1, d2,
metricm1
, dateTimeFieldSpecsdt1,dt2
.Primary time =
dt1
If the primary time column is timeFieldSpecs, the segment metadata will look like this
E.g: schema has dimensions
d1, d2,
metricm1
, dateTimeFieldSpecsdt1,dt2
, timeFieldSpect
Primary time =
t