Skip to content

Commit

Permalink
Feat: Process streams using deterministic (alpha-sorted) ordering (#335)
Browse files Browse the repository at this point in the history
  • Loading branch information
aaronsteers authored Aug 10, 2024
1 parent 23da920 commit 9bb782e
Showing 1 changed file with 6 additions and 2 deletions.
8 changes: 6 additions & 2 deletions airbyte/_future_cdk/record_processor.py
Original file line number Diff line number Diff line change
Expand Up @@ -252,8 +252,12 @@ def write_all_stream_data(
write_strategy: WriteStrategy,
progress_tracker: ProgressTracker,
) -> None:
"""Finalize any pending writes."""
for stream_name in self.catalog_provider.stream_names:
"""Finalize any pending writes.
Streams are processed in alphabetical order, so that order is deterministic and opaque,
without resorting to knowledge about catalog declaration order.
"""
for stream_name in sorted(self.catalog_provider.stream_names):
self.write_stream_data(
stream_name,
write_strategy=write_strategy,
Expand Down

0 comments on commit 9bb782e

Please sign in to comment.