abhishekagarwal87 commented on code in PR #12852:
URL: https://github.com/apache/druid/pull/12852#discussion_r942084771


##########
indexing-service/src/main/java/org/apache/druid/indexing/common/task/batch/parallel/InputSourceSplitParallelIndexTaskRunner.java:
##########
@@ -86,13 +83,8 @@ final SubTaskSpec<T> newTaskSpec(InputSplit split)
   {
     final FirehoseFactory firehoseFactory;
     final InputSource inputSource;
-    if (baseInputSource instanceof FirehoseFactoryToInputSourceAdaptor) {
-      firehoseFactory = ((FirehoseFactoryToInputSourceAdaptor) 
baseInputSource).getFirehoseFactory().withSplit(split);
-      inputSource = null;
-    } else {
-      firehoseFactory = null;
-      inputSource = baseInputSource.withSplit(split);
-    }
+    firehoseFactory = null;
+    inputSource = baseInputSource.withSplit(split);

Review Comment:
   would this work if baseInputSource is an adapter input source from a parser? 



##########
indexing-service/src/main/java/org/apache/druid/indexing/common/task/IndexTask.java:
##########
@@ -1196,16 +1190,9 @@ public InputFormat getInputFormat()
       return inputFormat;
     }
 
-    public InputSource getNonNullInputSource(@Nullable InputRowParser 
inputRowParser)
+    public InputSource getNonNullInputSource()

Review Comment:
   this too needs a fix similar to the one you did in SeekableStreamSampler. We 
need to keep the adapters around. 



##########
indexing-service/src/main/java/org/apache/druid/indexing/common/task/batch/parallel/ParallelIndexIngestionSpec.java:
##########
@@ -45,9 +44,7 @@ public ParallelIndexIngestionSpec(
     super(dataSchema, ioConfig, tuningConfig);
 
     if (dataSchema.getParserMap() != null && ioConfig.getInputSource() != 
null) {
-      if (!(ioConfig.getInputSource() instanceof 
FirehoseFactoryToInputSourceAdaptor)) {
-        throw new IAE("Cannot use parser and inputSource together. Try using 
inputFormat instead of parser.");
-      }
+      throw new IAE("Cannot use parser and inputSource together. Try using 
inputFormat instead of parser.");

Review Comment:
   what if the parserMap is not null and input source is an adapter input 
source? 



-- 
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.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to