feat: Implement gRPC Reflection Service (#340)
Co-authored-by: Samani G. Gikandi <[email protected]>
This commit is contained in:
co-authored by
Samani G. Gikandi
parent
f49d4bdf99
commit
c54f24721c
+9
-1
@@ -1,10 +1,18 @@
|
||||
use std::env;
|
||||
use std::path::PathBuf;
|
||||
|
||||
fn main() {
|
||||
tonic_build::configure()
|
||||
.type_attribute("routeguide.Point", "#[derive(Hash)]")
|
||||
.compile(&["proto/routeguide/route_guide.proto"], &["proto"])
|
||||
.unwrap();
|
||||
|
||||
tonic_build::compile_protos("proto/helloworld/helloworld.proto").unwrap();
|
||||
let out_dir = PathBuf::from(env::var("OUT_DIR").unwrap());
|
||||
tonic_build::configure()
|
||||
.file_descriptor_set_path(out_dir.join("helloworld_descriptor.bin"))
|
||||
.compile(&["proto/helloworld/helloworld.proto"], &["proto"])
|
||||
.unwrap();
|
||||
|
||||
tonic_build::compile_protos("proto/echo/echo.proto").unwrap();
|
||||
|
||||
tonic_build::configure()
|
||||
|
||||
Reference in New Issue
Block a user