cecemei commented on code in PR #18223:
URL: https://github.com/apache/druid/pull/18223#discussion_r2208133263


##########
processing/src/main/java/org/apache/druid/timeline/DataSegment.java:
##########
@@ -98,6 +99,7 @@ public static class PruneSpecsHolder
   private final Map<String, Object> loadSpec;
   private final List<String> dimensions;
   private final List<String> metrics;
+  private final List<String> projections;

Review Comment:
   It's somewhat implied that it's just projection names, similar to how 
metrics and dimensions are listed by name, not by their full definitions. 
   



##########
server/src/main/java/org/apache/druid/metadata/IndexerSQLMetadataStorageCoordinator.java:
##########
@@ -1203,18 +1203,12 @@ private SegmentPublishResult 
commitAppendSegmentsAndMetadataInTransaction(
             final SegmentId newVersionSegmentId = 
pendingSegment.getId().asSegmentId();
             newVersionSegmentToParent.put(newVersionSegmentId, 
oldSegment.getId());
             upgradedFromSegmentIdMap.put(newVersionSegmentId.toString(), 
oldSegment.getId().toString());
-            allSegmentsToInsert.add(
-                new DataSegment(
-                    pendingSegment.getId().asSegmentId(),
-                    oldSegment.getLoadSpec(),
-                    oldSegment.getDimensions(),
-                    oldSegment.getMetrics(),
-                    pendingSegment.getId().getShardSpec(),
-                    oldSegment.getLastCompactionState(),
-                    oldSegment.getBinaryVersion(),
-                    oldSegment.getSize()
-                )
-            );
+            allSegmentsToInsert.add(DataSegment.builder(oldSegment)
+                                               
.dataSource(newVersionSegmentId.getDataSource())

Review Comment:
   true, 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.

To unsubscribe, e-mail: commits-unsubscr...@druid.apache.org

For queries about this service, please contact Infrastructure at:
us...@infra.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscr...@druid.apache.org
For additional commands, e-mail: commits-h...@druid.apache.org

Reply via email to