Skip to content

Fix s3queue deduplication - #95467

Merged
kssenii merged 16 commits into
masterfrom
s3queue-deduplication
Feb 17, 2026
Merged

kssenii merged 16 commits into
masterfrom
s3queue-deduplication

Conversation

@kssenii

@kssenii kssenii commented Jan 28, 2026 •

Copy link
Copy Markdown
Member

Changelog category (leave one):

  • Bug Fix

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

Fix deduplication for streaming from S3(Azure)Queue engine.

Documentation entry for user-facing changes

  • Documentation is written (mandatory for new features)

Version info

  • Merged into: 26.2.1.837

@clickhouse-gh

clickhouse-gh Bot commented Jan 28, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [37f7f81]

Summary: ✅

@clickhouse-gh clickhouse-gh Bot added the pr-improvement Pull request with some product improvements label Jan 28, 2026
@kssenii
kssenii marked this pull request as ready for review January 30, 2026 14:29

@CheSema CheSema left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

All is good.

But I see that some s3 queue tests has failed, it is better check them

@kssenii
kssenii force-pushed the s3queue-deduplication branch from 8558815 to 09c4a83 Compare February 2, 2026 18:51
@kssenii
kssenii force-pushed the s3queue-deduplication branch from c664763 to 7b83f1b Compare February 4, 2026 15:15
@kssenii
kssenii requested a review from CheSema February 5, 2026 13:40
/// Create unique token per chunk: etag + row offset
dedup_token = fmt::format("{}:{}", etag, row_offset);

auto deduplication_info = DeduplicationInfo::create(/*async_insert*/true);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is the most unclear line.
Lets add a comment here.
Something like that:
when is_deduplication_v2 is true, all the source chunks are marked with DeduplicationInfo. Each chunk could have several pieces from different source files with unique deduplication token. In order to utilize deduplication with multiple tokens we set up insert pipeline as async_insert

/*no_destination=*/ true,
/*async_insert_=*/ false);
/*async_insert*/ is_deduplication_v2);

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is also unclear line.
actually this wont have significant influence. But it is better to have it the same as first line.

@kssenii
kssenii added this pull request to the merge queue Feb 17, 2026
Merged via the queue into master with commit 675a4e8 Feb 17, 2026
131 checks passed
@kssenii
kssenii deleted the s3queue-deduplication branch February 17, 2026 11:52
@robot-clickhouse-ci-1 robot-clickhouse-ci-1 added the pr-synced-to-cloud The PR is synced to the cloud repo label Feb 17, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

pr-improvement Pull request with some product improvements pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants