jihoonson commented on a change in pull request #9274: Refactoring some codes
around ingestion
URL: https://github.com/apache/druid/pull/9274#discussion_r374439260
##########
File path:
indexing-service/src/main/java/org/apache/druid/indexing/common/task/CachingLocalSegmentAllocator.java
##########
@@ -59,30 +60,46 @@
*
* @return Information for segment preallocation
*/
- Map<Interval, List<SegmentIdWithShardSpec>> create(Function<Interval,
String> versionFinder);
+ Map<Interval, List<SegmentIdWithShardSpec>> create(
+ TaskToolbox toolbox,
+ String dataSource,
+ Function<Interval, String> versionFinder
+ );
}
- CachingLocalSegmentAllocatorHelper(
+ CachingLocalSegmentAllocator(
TaskToolbox toolbox,
+ String dataSource,
String taskId,
- String supervisorTaskId,
+ @Nullable SupervisorTaskAccess supervisorTaskAccess,
IntervalToSegmentIdsCreator intervalToSegmentIdsCreator
) throws IOException
{
this.taskId = taskId;
this.sequenceNameToSegmentId = new HashMap<>();
+ final TaskAction<List<TaskLock>> action;
+ if (supervisorTaskAccess == null) {
+ action = new LockListAction();
+ } else {
+ action = new
SurrogateAction<>(supervisorTaskAccess.getSupervisorTaskId(), new
LockListAction());
+ }
Review comment:
Same, this class will be removed.
----------------------------------------------------------------
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]