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_r262329251
 
 

 ##########
 File path: 
indexing-service/src/main/java/org/apache/druid/indexing/firehose/WindowedSegmentId.java
 ##########
 @@ -0,0 +1,61 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *   http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+
+package org.apache.druid.indexing.firehose;
+
+import com.fasterxml.jackson.annotation.JsonCreator;
+import com.fasterxml.jackson.annotation.JsonProperty;
+import com.google.common.base.Preconditions;
+import org.joda.time.Interval;
+
+import java.util.List;
+
+/**
+ * A WindowedSegment represents a segment plus the list of intervals inside it 
which contribute to a timeline.
+ * <p>
+ * This class is intended for serialization in specs.
+ */
+public class WindowedSegmentId
 
 Review comment:
   The goal here is to ensure that we only send a given segment to one subtask, 
even if it has multiple windows. So it seemed reasonable to at least represent 
it in memory as an object that is "a segment with some windows". Does that seem 
right?
   
   It also seemed nice to keep the representation that shows up in the task 
spec simpler (just segment ids, not full DataSegment) though maybe that is the 
wrong tradeoff. I was especially leaning towards that when the idea was that 
you might manually write a spec with segment IDs.

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