mirror of https://github.com/apache/druid.git
Use durable super sorter intermediate storage only with composable storage (#13748)
* This enables usage of durable storage connector only in case the composable storage feature is enabled.
This commit is contained in:
parent
e16639121f
commit
c5835c29a1
|
@ -691,35 +691,22 @@ public class WorkerImpl implements Worker
|
|||
final FileOutputChannelFactory fileOutputChannelFactory =
|
||||
new FileOutputChannelFactory(fileChannelDirectory, frameSize, intermediateSuperSorterLocalStorageTracker);
|
||||
|
||||
if (MultiStageQueryContext.isComposedIntermediateSuperSorterStorageEnabled(QueryContext.of(task.getContext()))) {
|
||||
if (durableStageStorageEnabled) {
|
||||
return new ComposingOutputChannelFactory(
|
||||
ImmutableList.of(
|
||||
fileOutputChannelFactory,
|
||||
DurableStorageOutputChannelFactory.createStandardImplementation(
|
||||
task.getControllerTaskId(),
|
||||
task().getWorkerNumber(),
|
||||
stageNumber,
|
||||
task().getId(),
|
||||
frameSize,
|
||||
MSQTasks.makeStorageConnector(context.injector()),
|
||||
tmpDir
|
||||
)
|
||||
),
|
||||
frameSize
|
||||
);
|
||||
} else {
|
||||
return fileOutputChannelFactory;
|
||||
}
|
||||
} else if (durableStageStorageEnabled) {
|
||||
return DurableStorageOutputChannelFactory.createStandardImplementation(
|
||||
task.getControllerTaskId(),
|
||||
task().getWorkerNumber(),
|
||||
stageNumber,
|
||||
task().getId(),
|
||||
frameSize,
|
||||
MSQTasks.makeStorageConnector(context.injector()),
|
||||
tmpDir
|
||||
if (MultiStageQueryContext.isComposedIntermediateSuperSorterStorageEnabled(QueryContext.of(task.getContext())) &&
|
||||
durableStageStorageEnabled) {
|
||||
return new ComposingOutputChannelFactory(
|
||||
ImmutableList.of(
|
||||
fileOutputChannelFactory,
|
||||
DurableStorageOutputChannelFactory.createStandardImplementation(
|
||||
task.getControllerTaskId(),
|
||||
task().getWorkerNumber(),
|
||||
stageNumber,
|
||||
task().getId(),
|
||||
frameSize,
|
||||
MSQTasks.makeStorageConnector(context.injector()),
|
||||
tmpDir
|
||||
)
|
||||
),
|
||||
frameSize
|
||||
);
|
||||
} else {
|
||||
return fileOutputChannelFactory;
|
||||
|
|
Loading…
Reference in New Issue