jihoonson commented on a change in pull request #9274: Refactoring some codes
around ingestion
URL: https://github.com/apache/druid/pull/9274#discussion_r374439275
##########
File path:
indexing-service/src/main/java/org/apache/druid/indexing/common/task/CachingLocalSegmentAllocator.java
##########
@@ -115,14 +132,11 @@ public SegmentIdWithShardSpec allocate(
boolean skipSegmentLineageCheck
)
{
- return sequenceNameToSegmentId.get(sequenceName);
- }
-
- @Override
- public String getSequenceName(Interval interval, InputRow inputRow)
- {
- // Sequence name is based solely on the shardSpec, and there will only be
one segment per sequence.
- return getSequenceName(interval, shardSpecs.getShardSpec(interval,
inputRow));
+ return Preconditions.checkNotNull(
Review comment:
The `CachingLocalSegmentAllocator` allocates all necessary segment IDs
upfront and returns a proper segment ID corresponding to the `sequenceName`.
It's a bug if there's a missing segment ID for a sequence.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]
With regards,
Apache Git Services
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]