mirror of https://github.com/apache/druid.git
1) Fix bug with sharded realtime data ingestion
This commit is contained in:
parent
8a49c156ed
commit
f062e136d0
|
@ -194,6 +194,11 @@ public class DataSegment implements Comparable<DataSegment>
|
|||
return builder(this).loadSpec(loadSpec).build();
|
||||
}
|
||||
|
||||
public DataSegment withDimensions(List<String> dimensions)
|
||||
{
|
||||
return builder(this).dimensions(dimensions).build();
|
||||
}
|
||||
|
||||
public DataSegment withSize(long size)
|
||||
{
|
||||
return builder(this).size(size).build();
|
||||
|
|
|
@ -307,16 +307,7 @@ public class RealtimePlumberSchool implements PlumberSchool
|
|||
|
||||
DataSegment segment = segmentPusher.push(
|
||||
mergedFile,
|
||||
new DataSegment(
|
||||
schema.getDataSource(),
|
||||
interval,
|
||||
interval.getStart().toString(),
|
||||
null,
|
||||
Lists.newArrayList(index.getAvailableDimensions()),
|
||||
Lists.newArrayList(index.getAvailableMetrics()),
|
||||
new NoneShardSpec(),
|
||||
0
|
||||
)
|
||||
sink.getSegment().withDimensions(Lists.newArrayList(index.getAvailableDimensions()))
|
||||
);
|
||||
|
||||
metadataUpdater.publishSegment(segment);
|
||||
|
@ -325,7 +316,6 @@ public class RealtimePlumberSchool implements PlumberSchool
|
|||
log.makeAlert(e, "Failed to persist merged index[%s]", schema.getDataSource())
|
||||
.addData("interval", interval)
|
||||
.emit();
|
||||
return;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue