Skip to content

Commit

Permalink
Pipe: Fixed the bug that different types in schema snapshot transfer …
Browse files Browse the repository at this point in the history
…may cause transfer failure (#13627) (#13631)
  • Loading branch information
Caideyipi authored Sep 26, 2024
1 parent 3c02466 commit cf1e890
Showing 1 changed file with 12 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -313,6 +313,18 @@ private void executeInternalCreateAlignedTimeSeries(
encodingList.remove(index);
compressionTypeList.remove(index);

// If with merge is set, the lists are deep copied and need to be altered here.
// We still remove the element from the original list to help cascading pipe transfer
// schema.
// If this exception is thrown, the measurements, data types, etc. must be unchanged.
// Thus, the index for the copied lists are identical to that in the original lists.
if (withMerge) {
createAlignedTimeSeriesPlan.getMeasurements().remove(index);
createAlignedTimeSeriesPlan.getDataTypes().remove(index);
createAlignedTimeSeriesPlan.getEncodings().remove(index);
createAlignedTimeSeriesPlan.getCompressors().remove(index);
}

if (measurementList.isEmpty()) {
shouldRetry = false;
}
Expand Down

0 comments on commit cf1e890

Please sign in to comment.