Skip to content

Cap'n Proto RPC ByteStream uses more CPU than gRPC bidirectional streaming #608

@shizhx

Description

@shizhx

Same condition:

  • bandwidth: 1Gbps
  • block size : 1500

toplogy:
iperf3 client -> proxy-bench client -> proxy-bench server -> iperf3 server

capnp rpc:
Image

Image

gRPC:
Image

Image

Core Code here:
https://github.com/shizhx/proxy-bench/blob/096738d67bd80a936207c2bdf1b261da898a0ae9/capnpnet/capnp_net.go#L244-L274

https://github.com/shizhx/proxy-bench/blob/096738d67bd80a936207c2bdf1b261da898a0ae9/capnpnet/capnp_net.go#L187-L217

Why is that? Shouldn't Cap'n Proto have less overhead since it doesn't involve serialization and deserialization?

This is my first time working with Cap'n Proto RPC. If there are any issues with the code, please feel free to point them out. Thank you!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions