Describe the bug
Our system heavily relies on grpc and protobuf. However, Rust crate prost! used to process protobuf message has some potential bugs in Rust's latest stable release 1.61 .
My investigation suggests that in Rust 1.61, prost!'s encode_to_vec() method has inconsistent behaviors when encode protobuf message, which may generate wrong code bytes, and then it leads to the rpc server's decode error: "buffer underflow"
To Reproduce
Steps to reproduce the behavior:
- Go to '.../GraphScope/research/query_service/ir/compiler'
make install
cd ..
RUST_LOG=info ./target/release/start_rpc_server --config ./integrated/config/
- open another terminal tab,
cd compiler && make run graph.schema:=../core/resource/modern_schema.json
- open another terminak tab,
cd compiler && make gremlin_test
Then you can see the protobuf buffer underflow error
Expected behavior
Pass all the test
Environment (please complete the following information):
- GraphScope version: latest main
- OS: macOS 12.4 with rust 1.61 or Linux Docker with rust 1.61 image
Therefore, currently it is not suggested to update to Rust 1.61
Describe the bug
Our system heavily relies on grpc and protobuf. However, Rust crate
prost!used to process protobuf message has some potential bugs in Rust's latest stable release 1.61 .My investigation suggests that in Rust 1.61, prost!'s
encode_to_vec()method has inconsistent behaviors when encode protobuf message, which may generate wrong code bytes, and then it leads to the rpc server's decode error: "buffer underflow"To Reproduce
Steps to reproduce the behavior:
make installcd ..RUST_LOG=info ./target/release/start_rpc_server --config ./integrated/config/cd compiler && make run graph.schema:=../core/resource/modern_schema.jsoncd compiler && make gremlin_testThen you can see the protobuf buffer underflow error
Expected behavior
Pass all the test
Environment (please complete the following information):
Therefore, currently it is not suggested to update to Rust 1.61