Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Remove _types suffix from name of types crate
Summary: The Rust Thrift implementation presently compiles to 4 crates: ```lang=mermaid flowchart TD; foo --> foo-clients; foo --> foo-types; foo --> foo-services; foo-clients --> foo-types; foo-services --> foo-types; ``` Sadly, the one with the best name is the most useless. That top-level foo crate just contains the following: ``` pub use ::foo_types as types; pub use ::foo_clients as client; pub use ::foo_services as server; pub use ::foo_types::consts; pub use ::foo_types::errors; pub use ::foo_types::services; pub use ::foo_clients::mock; pub use self::consts::*; pub use self::errors::*; pub use self::types::*; ``` Furthermore, it is extremely uncommon for anything to want to be both a client and a server of the *same* Thrift interface. It arises occasionally for proxies, but otherwise you are either implementing the server for a particular service, or accessing it as a client, not both. I am interested in eliminating the useless crate, and renaming the types subcrate to the nice name. ```lang=mermaid flowchart TD; foo-clients --> foo; foo-services --> foo; ``` ### Implementation plan 1. This diff 2. Migrate everything that uses `:foo-rust` and needs a client to `:foo-rust-clients`, and everything that needs a server to `:foo-rust-services` -- after this point, everything still depending on `:foo-rust` only uses types 3. In the macros, atomically delete `:foo-rust` and rename `:foo-rust-types` into its place (this will be a small diff) Reviewed By: zertosh, shayne-fletcher Differential Revision: D53302058 fbshipit-source-id: 8d28c90f3a13e71e0cedd3ce3c1cb6fe40cffe27
- Loading branch information