Skip to content

feat: add gRPC Settings tab with configurable channel options, deadlines, and proto-loader settings #7737

@sanish-bruno

Description

@sanish-bruno

Summary

Add a Settings tab to the gRPC request pane, exposing commonly needed gRPC configuration options. This addresses multiple user pain points:

  • 4MB message size limit (#7718) — the @grpc/grpc-js library defaults to 4MB max receive message length, making Bruno unusable for large gRPC responses
  • No deadline support — many gRPC servers require a deadline (#6875) and reject requests without one, making Bruno unusable for those APIs
  • No control over proto-loader options — users cannot toggle whether protobuf default values are included in responses

Settings Exposed

Channel Options (connection/transport level)

Setting gRPC Option Type Default
Max Receive Message Size grpc.max_receive_message_length bytes -1 (unlimited)
Max Send Message Size grpc.max_send_message_length bytes -1 (unlimited)
Keepalive Time grpc.keepalive_time_ms ms library default
Keepalive Timeout grpc.keepalive_timeout_ms ms library default
Client Idle Timeout grpc.client_idle_timeout_ms ms library default
Max Reconnect Backoff grpc.max_reconnect_backoff_ms ms library default

Call Options (per-RPC level)

Setting Type Default
Deadline ms no deadline

Proto-loader Options (response format)

Setting Type Default
Include Default Values boolean toggle true

Implementation Details

Default channel options

Sets grpc.max_receive_message_length and grpc.max_send_message_length to -1 (unlimited) by default. As a client-side API tool, Bruno should not impose arbitrary limits on message sizes. This matches the behavior of other gRPC clients (grpcurl, Postman).

Deadline support

All four RPC handler methods (makeUnaryRequest, makeClientStreamRequest, makeServerStreamRequest, makeBidiStreamRequest) now accept and pass CallOptions with a deadline property when configured.

Proto-loader defaults option

For proto file loading: the defaults option is passed through to protoLoader.load().
For reflection loading: replaced client.listMethods() (which hardcodes proto-loader options) with lower-level calls (getDescriptorBySymbolgetPackageObject(options)getServiceMethods) to support custom proto-loader options.

Settings persistence

Settings are persisted in the .bru file format via the existing settings block:

settings {
  maxReceiveMessageLength: -1
  deadline: 5000
  includeDefaultValues: true
}

Metadata

Metadata

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions