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

fix(core): Ensure followers do not recover executions from logs #9785

Merged
merged 1 commit into from
Jun 18, 2024

Conversation

ivov
Copy link
Contributor

@ivov ivov commented Jun 17, 2024

@n8n-assistant n8n-assistant bot added core Enhancement outside /nodes-base and /editor-ui n8n team Authored by the n8n team labels Jun 17, 2024
) {}

/**
* Recover key properties of a truncated execution using event logs.
*/
async recoverFromLogs(executionId: string, messages: EventMessageTypes[]) {
if (this.orchestrationService.isFollower) return;
Copy link
Member

Choose a reason for hiding this comment

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

Would it make sense to move this check to this line instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

My reasoning for making the leadership check internal to the service is to prevent someone in future using recoverFromLogs elsewhere and forgetting to account for leadership. This follows the pattern in WaitTracker and PruningService.

Copy link
Contributor

✅ No visual regressions found.

Copy link

cypress bot commented Jun 18, 2024

1 flaky test on run #5546 ↗︎

0 394 0 0 Flakiness 1

Details:

🌳 🖥️ browsers:node18.12.0-chrome107 🤖 ivov 🗃️ e2e/*
Project: n8n Commit: 0ae1e8ee65
Status: Passed Duration: 05:30 💡
Started: Jun 18, 2024 8:34 AM Ended: Jun 18, 2024 8:39 AM
Flakiness  e2e/5-ndv.cy.ts • 1 flaky test

View Output Video

Test Artifacts
NDV > Stop listening for trigger event from NDV Screenshots Video

Review all test suite changes for PR #9785 ↗︎

Copy link
Contributor

✅ All Cypress E2E specs passed

@ivov ivov merged commit 7c358e5 into master Jun 18, 2024
35 of 36 checks passed
@ivov ivov deleted the pay-1682 branch June 18, 2024 08:52
This was referenced Jun 20, 2024
@janober
Copy link
Member

janober commented Jun 20, 2024

Got released with [email protected]

1 similar comment
@janober
Copy link
Member

janober commented Jun 20, 2024

Got released with [email protected]

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
core Enhancement outside /nodes-base and /editor-ui n8n team Authored by the n8n team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants