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

MINOR: refactoring periodic tasks to wrap a ControllerWriteOperation #19245

Open
wants to merge 1 commit into
base: trunk
Choose a base branch
from

Conversation

kevin-wu24
Copy link
Contributor

Refactor periodic tasks framework to wrap a ControllerWriteOperation, not just a Supplier<ControllerResult<Boolean>>.

@github-actions github-actions bot added kraft small Small PRs triage PRs from the community labels Mar 19, 2025
}

PeriodicTask(
String name,
Supplier<ControllerResult<Boolean>> op,
QuorumController.ControllerWriteOperation<Boolean> writeOp,
Copy link
Contributor

Choose a reason for hiding this comment

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

I think it would be better to have a separate callback like a Consumer<Long> that we can pass in here. Making people implement QuorumController.ControllerWriteOperation feels a bit messy since that's an inner class of QuorumController. It's also a bit confusing (to me, at least)

@github-actions github-actions bot removed the triage PRs from the community label Mar 22, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants