tikv: Cargo Run workflow no longer usable
Bug Report
What version of TiKV are you using? master
What operating system and CPU are you using? Any
What did you do?
As is convention in the Rust ecosystem, as I have for the last year and a half, I ran cargo run --bin tikv-server
to start a TiKV development build of the server.
The command reported:
error: no bin target named `tikv-server`
The README.md does not describe how to workaround this problem.
The target machine does not have access to a copy of make
that can support the complex Makefile.
What did you expect to see?
TiKV, as a rust project, to build and operate like a Rust project.
TiKV, as a repository of tikv project, should follow the conventions of our other rust projects and support a clean cargo run
behavior.
What did you see instead?
error: no bin target named `tikv-server`
What action should be taken?
I suggest reverting https://github.com/tikv/tikv/pull/5242 or adding documentation to all of our README files, as well as our /Cargo.toml
documenting this.
I would prefer reverting https://github.com/tikv/tikv/pull/5242. I think this has very poor usability for folks trying out contributing or developing TiKV for their first time.
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 19 (19 by maintainers)
Also the default-members key might help us here. It specifies the “main package”, the one that is selected by default for
run
-style commands.Since tikv is so huge now it probably would make sense to turn the main manifest into a pure workspace, and put everything into a sub-component, then use default-members and maybe default-run.
Also we might use the new (?) default-run key to make tikv-server run without picking an explicit bin
I also agree that
cargo run
should just work.If the problem is that tikv-server/ctl is going to depend on a library that itself depends on tikv, then we can make tikv another ‘component’ and make the top-level manifest just hold the bins.