drmingdrmer / openraft

An implementation of the Raft distributed consensus protocol using the Tokio framework.
https://datafuselabs.github.io/openraft/
Apache License 2.0
1 stars 1 forks source link

Refactor: replace the trait bound RaftTypeConfig of LeaderId with NodeId #23

Closed drmingdrmer closed 2 years ago

drmingdrmer commented 2 years ago

Try to simplify trait bound in the latest PR: https://github.com/datafuselabs/openraft/pull/220

Use specific trait bound instead of the wrapper trait RaftTypeConfig if possible. E.g. replace LeaderId<C: RaftTypeConfig> with LeaderId<NID: NodeID>.