Skip to content

Conversation

@KKcorps
Copy link
Contributor

@KKcorps KKcorps commented Sep 27, 2022

Currently, if time format is EPOCH. we store the time metadata in zookeeper in the timeUnit specified in the format. e.g for 1:EPOCH:SECONDS we will store time in seconds.
This only increases complexity while processing metadata and also uses extra space in zookeeper to store timeUnit String for each segment.

The PR aims to make a small change to always store time in milliseconds. The TimeUnit hasn't been removed from Zookeeper so as to maintain backward compatibility.

@codecov-commenter
Copy link

codecov-commenter commented Sep 27, 2022

Codecov Report

Merging #9472 (70f0d02) into master (83b7f15) will decrease coverage by 6.27%.
The diff coverage is 66.66%.

@@             Coverage Diff              @@
##             master    #9472      +/-   ##
============================================
- Coverage     69.89%   63.61%   -6.28%     
- Complexity     4742     5109     +367     
============================================
  Files          1910     1857      -53     
  Lines        101787    99477    -2310     
  Branches      15445    15178     -267     
============================================
- Hits          71139    63286    -7853     
- Misses        25628    31536    +5908     
+ Partials       5020     4655     -365     
Flag Coverage Δ
integration1 ?
integration2 ?
unittests1 67.14% <66.66%> (-0.01%) ⬇️
unittests2 15.50% <0.00%> (+<0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

Impacted Files Coverage Δ
...ment/creator/impl/SegmentColumnarIndexCreator.java 78.70% <66.66%> (-0.24%) ⬇️
...va/org/apache/pinot/core/routing/RoutingTable.java 0.00% <0.00%> (-100.00%) ⬇️
...va/org/apache/pinot/common/config/NettyConfig.java 0.00% <0.00%> (-100.00%) ⬇️
...a/org/apache/pinot/common/metrics/MinionMeter.java 0.00% <0.00%> (-100.00%) ⬇️
...g/apache/pinot/common/metrics/ControllerMeter.java 0.00% <0.00%> (-100.00%) ⬇️
.../apache/pinot/common/metrics/BrokerQueryPhase.java 0.00% <0.00%> (-100.00%) ⬇️
.../apache/pinot/common/metrics/MinionQueryPhase.java 0.00% <0.00%> (-100.00%) ⬇️
...ache/pinot/server/access/AccessControlFactory.java 0.00% <0.00%> (-100.00%) ⬇️
...he/pinot/common/messages/SegmentReloadMessage.java 0.00% <0.00%> (-100.00%) ⬇️
...he/pinot/common/messages/TableDeletionMessage.java 0.00% <0.00%> (-100.00%) ⬇️
... and 428 more

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more

Copy link
Contributor

@Jackie-Jiang Jackie-Jiang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggest making the change in ZKMetadataUtils.updateSegmentZKMetadata() for now. That way even if we push old generated segment, we will still get the millis start/end time. Currently SegmentMetadataImpl._timeGranularity relies on the time unit, so if we want to change the time unit in segment metadata, we want to clean it up to prevent unexpected behavior

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants