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

Change: change LogId<NID:NodeId> to LogId<C:RaftTypeConfig> #1281

Merged
merged 1 commit into from
Dec 25, 2024

Conversation

drmingdrmer
Copy link
Member

@drmingdrmer drmingdrmer commented Dec 25, 2024

Changelog

Change: change LogId<NID:NodeId> to LogId<C:RaftTypeConfig>

This refactoring moves LogId from a per-NodeId type to a per-TypeConfig type,
to make it consistent with RaftTypeConfig usage across the codebase.

Upgrade tip:

LogId is now parameterized by RaftTypeConfig instead of NodeId

  • Change LogId<NodeId> to LogId<C> where C: RaftTypeConfig, for
    example, change LogId<u64> to LogId<YourTypeConfig>.

  • Change trait RaftLogId<NID: NodeId> to RaftLogId<C: RaftTypeConfig>.


This change is Reviewable

This refactoring moves LogId from a per-NodeId type to a per-TypeConfig type,
to make it consistent with `RaftTypeConfig` usage across the codebase.

- Part of: databendlabs#1278

Upgrade tip:

LogId is now parameterized by `RaftTypeConfig` instead of `NodeId`

- Change `LogId<NodeId>` to `LogId<C> where C: RaftTypeConfig`, for
  example, change `LogId<u64>` to `LogId<YourTypeConfig>`.

- Change trait `RaftLogId<NID: NodeId>` to `RaftLogId<C: RaftTypeConfig>`.
@drmingdrmer drmingdrmer merged commit 4d36290 into databendlabs:main Dec 25, 2024
32 of 33 checks passed
@drmingdrmer drmingdrmer deleted the 163-logid-c branch December 25, 2024 07:04
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant