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 settlement updater #3018

Merged
merged 5 commits into from
Sep 27, 2024
Merged

Move settlement updater #3018

merged 5 commits into from
Sep 27, 2024

Conversation

sunce86
Copy link
Contributor

@sunce86 sunce86 commented Sep 27, 2024

Description

OnSettlementEventUpdater was previously refactored and ended up being dependent on domain and infra objects only.

That means it is ready to be moved to a proper place inside domain.

Changes

  • Moved updater to domain::settlement::on_event module
  • Updated EventIndexer to call deletion of settlement dependent data directly.

How to test

Existing e2e tests.

@sunce86 sunce86 self-assigned this Sep 27, 2024
@sunce86 sunce86 requested a review from a team as a code owner September 27, 2024 09:13
Copy link
Contributor

@m-lord-renkse m-lord-renkse left a comment

Choose a reason for hiding this comment

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

I like the new naming.

Copy link
Contributor

@MartinquaXD MartinquaXD left a comment

Choose a reason for hiding this comment

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

nit: The "to be renamed component" is the only one that creates settlement::Settlement instances (the infra is the only one consuming it). That means settlement::Settlement::new() can now be made private. That way we ensure that we don't have other components create these types by accident.

crates/autopilot/src/domain/settlement/on_event.rs Outdated Show resolved Hide resolved
Copy link
Contributor

@squadgazzz squadgazzz left a comment

Choose a reason for hiding this comment

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

LGTM

@sunce86 sunce86 enabled auto-merge (squash) September 27, 2024 13:20
@sunce86 sunce86 merged commit b585cdd into main Sep 27, 2024
10 of 11 checks passed
@sunce86 sunce86 deleted the move-settlement-updater branch September 27, 2024 13:31
@github-actions github-actions bot locked and limited conversation to collaborators Sep 27, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants