Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Move the poll interval logic from the streaming source to corrdinator #19

Closed
morozov opened this issue Mar 2, 2021 · 0 comments · Fixed by #31
Closed

Move the poll interval logic from the streaming source to corrdinator #19

morozov opened this issue Mar 2, 2021 · 0 comments · Fixed by #31
Assignees
Labels
SQL Server Debezium connector for SQL Server

Comments

@morozov
Copy link

morozov commented Mar 2, 2021

Instead of pausing after not having seen any updates in a given database (source-level logic), the partitioned connector should pause after not having seen changes in any of its partitions. So this logic should be moved from SqlServerStreamingChangeEventSource to PartitionedChangeEventSourceCoordinator (#16).

Acceptance criteria:
When streaming changes, the connector should pause between iterations.

Previous logic:

while (true) {
    if (!hasChanges(databaseName)) {
        sleep();
    }
}

Required logic:

while (true) {
    hasChanges = false;

    for (databaseName : databaseNames) {
        if (hasChanges(db)) {
            hasChanges = true;
        }
    }

    if (!hasChanges) {
        sleep();
    }
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
SQL Server Debezium connector for SQL Server
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants