commit | 5ba80646bf2c845e02ba0188ad8095725a90607f | [log] [tgz] |
---|---|---|
author | Wyatt Hepler <hepler@google.com> | Fri Jun 18 12:56:17 2021 -0700 |
committer | CQ Bot Account <pigweed-scoped@luci-project-accounts.iam.gserviceaccount.com> | Wed Jun 23 00:56:39 2021 +0000 |
tree | ff6496a672c17b7b28f4d45831448d35e517c4b1 | |
parent | 25fd893156f43734751f3f3a6529cb1cbbc89c1b [diff] |
pw_rpc: Update protocol for server streams Update the server-to-client RPC packet types so that the packet type unambiguously indicates whether it is the first or last packet. This is already the case for client-to-server RPC packet types. - Have RESPONSE always be the last packet in the stream. For RPCs without a server stream, it includes a payload. Remove SERVER_STREAM_END. - Introduce the SERVER_STREAM packet, to parallel the CLIENT_STREAM packet. - Update the server and client code and tests. Test that old-style streaming RPCs still work correctly. - Refactor the duplicate MessageOutput class into a FakeChannelOutput used by both Nanopb and raw RPCs. - In C++, don't encode default-valued payload and status fields. Change-Id: I218772dad6c2981dda5f032f298ea43ee5e08b4d Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/49822 Commit-Queue: Wyatt Hepler <hepler@google.com> Pigweed-Auto-Submit: Wyatt Hepler <hepler@google.com> Reviewed-by: Alexei Frolov <frolv@google.com>
See our website: http://pigweed.dev