glasser commented on a change in pull request #7048: Make 
IngestSegmentFirehoseFactory splittable for parallel ingestion
URL: https://github.com/apache/incubator-druid/pull/7048#discussion_r264387687
 
 

 ##########
 File path: 
indexing-service/src/test/java/org/apache/druid/indexing/firehose/IngestSegmentFirehoseFactoryTimelineTest.java
 ##########
 @@ -286,13 +331,26 @@ private static InputRow ir(String timeString, long 
metricValue)
             throw new IllegalArgumentException("WTF");
           }
         }
+
+        @Override
+        public DataSegment getDatabaseSegmentDataSourceSegment(String 
dataSource, String segmentId)
+        {
+          return testCase.segments
+              .stream()
+              .filter(s -> s.getId().toString().equals(segmentId))
+              .findAny()
+              .get();  // throwing if not found is exactly what the real code 
does
 
 Review comment:
   TeamCity doesn't want me to call `Optional.get()` without `ifPresent()` 
because it might throw, but I'm OK with it throwing. Not sure if I should 
change anything?

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

Reply via email to