Skip to content

[raft] Define the admin interface of Raft groups - #1892

Closed
MariemBaccari wants to merge 1 commit into
interuss:masterfrom
Orbitalize:admin_interface_raft
Closed

MariemBaccari wants to merge 1 commit into
interuss:masterfrom
Orbitalize:admin_interface_raft

Conversation

@MariemBaccari

@MariemBaccari MariemBaccari commented Nov 2, 2026 •

Copy link
Copy Markdown
Contributor

This PR partially addresses #1719. It adds admin.RaftGroup, the Go interface for managing Raft group membership. It will be implemented, in follow-up PRs by the server and the client.

@mickmis mickmis left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Why is an interface required here?
Go-idiomatic code would define an interface alongside its consumer. So I'd actually see that piece of code belong more in #1777.
But if the implementer of the interface is anyway strongly coupled with its consumer, and that there are no alternative implementation planned, I think that is just introducing unnecessary abstractions. But I'm missing something?

Comment thread pkg/admin/raft_group.go
type Membership struct {
// ClusterID identifies the group within the cluster. It is identical on all the members of the group.
ClusterID uint64
LeaderID uint64

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

What is LeaderID?

Copy link
Copy Markdown
Contributor Author

Choose a reason for hiding this comment

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

It's the ID of the leader of the Raft group.

@MariemBaccari

Copy link
Copy Markdown
Contributor Author

As discussed offline, this interface is not needed anymore.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Status: Done

Development

Successfully merging this pull request may close these issues.

2 participants