Sets the compression to use for the call. The compressor must be a valid name known in the CompressorRegistry. By default, the "gzip" compressor will be available. It is only safe to call this if the server supports the compression format chosen. There is no negotiation performed; if t
(@Nullable String compressorName)
| 151 | * fail. |
| 152 | */ |
| 153 | public CallOptions withCompression(@Nullable String compressorName) { |
| 154 | Builder builder = toBuilder(this); |
| 155 | builder.compressorName = compressorName; |
| 156 | return builder.build(); |
| 157 | } |
| 158 | |
| 159 | /** |
| 160 | * Returns a new {@code CallOptions} with the given absolute deadline. |