QGrpcHttp2Channel: implement client-side request compression


Add a requestCompression option on QGrpcChannelOptions and
QGrpcCallOptions that selects a gzip or deflate algorithm for
compressing outbound RPC messages.

Wire behaviour follows the gRPC HTTP/2 specification:

- grpc-encoding is emitted once in the initial request headers.
- Each outbound frame is compressed independently. No context is
  retained across messages.
- If compression does not reduce the payload size the message is sent
  uncompressed with Compressed-Flag = 0.

The implementation uses zlib directly. For system zlib,
WrapZLIB::WrapZLIB must be linked explicitly because Qt::Core carries it
only as a private dependency. For the Qt-bundled zlib, no extra link
target is needed: Qt's zlib.h redefines ZEXTERN to Q_CORE_EXPORT, so the
z_-prefixed symbols are intentionally exported from Qt::Core and resolve
through the existing Qt::Core dependency.

[ChangeLog][QtGrpc][QGrpc{Call,Channel}Options] Added
setRequestCompression() to compress outbound RPC payloads with gzip or
deflate. Call options take precedence over channel options.

Fixes: QTBUG-140235
Change-Id: I33eeae20f3f3d07c01489b15e93b5441a15335a9
Reviewed-by: MÃ¥rten Nordheim <marten.nordheim@qt.io>
commitbdea8cf706d947951bfaaeaf20e1f742ad1b588a
parentde604ccd6ddac64eab0318f3f8628df6f610e001
authorDennis Oberst <dennis.oberst@qt.io>
committerDennis Oberst <dennis.oberst@qt.io>
commit timeMon, 1 Jun 2026 14:55:50 +0000