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 protos to a separate crate #247

Merged
merged 2 commits into from
Jun 19, 2019
Merged

Move protos to a separate crate #247

merged 2 commits into from
Jun 19, 2019

Conversation

nrc
Copy link
Contributor

@nrc nrc commented Jun 18, 2019

Makes Raft a workspace project

Motivated by pingcap/kvproto#280

PTAL @Hoverbear @BusyJay

Makes Raft a workspace project

Signed-off-by: Nick Cameron <nrc@ncameron.org>
@nrc nrc requested review from Hoverbear and BusyJay June 18, 2019 20:49
Signed-off-by: Nick Cameron <nrc@ncameron.org>
Copy link
Member

@BusyJay BusyJay left a comment

Choose a reason for hiding this comment

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

rest LGTM


[dependencies]
bytes = "0.4.11"
lazy_static = "1.3.0"
Copy link
Member

Choose a reason for hiding this comment

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

Why does it depend on lazy_static?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Some of the rust-protobuf API we are emulating requires an initialised default with static lifetime, lazy_static is the best way to support that.

Copy link
Member

Choose a reason for hiding this comment

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

Interesting. It may also be the reason why it doesn't perform as expected.

Copy link
Contributor

Choose a reason for hiding this comment

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

Could const fn help solve it one day?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Maybe, I'm not sure. I hope we can just eliminate uses of that wrapper function and then remove lazy static

@Hoverbear Hoverbear added this to the 0.6.0 milestone Jun 19, 2019
@Hoverbear Hoverbear added Feature Related to a major feature. and removed Feature Related to a major feature. labels Jun 19, 2019
@nrc nrc merged commit 7ba7760 into tikv:master Jun 19, 2019
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.

3 participants