Base class for Connect RPC clients: the shared Transport and the per-call deadline defaults.
A deadline is a per-call TimeoutSignal rather than a stub option, and it bounds the whole
logical call, retries included; the server still enforces its own per-attempt deadline.
A middleware over a Connect call, in the shape HTTP middleware usually takes: one method wraps
the whole request and response flow. The generic call satisfies connectrpc's Interceptor, so
an instance goes straight into a transport's interceptors: list, where the first entry is the
outermost layer.
The one transient-retry layer for the Connect transport: retries transient unary calls with
full-jitter exponential backoff (RetryBackoff), honoring server pushback
(grpc-retry-pushback-ms) and a total time budget. Retries elsewhere nest and amplify; do not
add them.
A generic empty message that you can re-use to avoid defining duplicated
empty messages in your APIs. A typical example is to use it as the request
or the response type of an API method. For instance:
Declares an API Interface to be included in this interface. The including
interface must redeclare all the methods from the included interface, but
documentation and options are inherited as follows:
The root CAs the pinned SecurityContext trusts. This set replaces the platform trust store,
so it has to cover every CA a backend can serve: Let's Encrypt ISRG Root X1 for RSA chains and
X2 for ECDSA chains, and Google Trust Services GTS Root R1 to R4 for hosts on Google
infrastructure.
Owns the platform HTTP client shared by the transports: create one, pass it to every
createConnectTransport, close it on teardown. One handle lets every service multiplex the
per-origin HTTP/2 connections.
Struct represents a structured data value, consisting of fields
which map to dynamically typed values. In some languages, Struct
might be supported by a native representation. For example, in
scripting languages like JS a struct is represented as an
object. The details of that representation are described together
with the proto support for the language.
A Timestamp represents a point in time independent of any time zone or local
calendar, encoded as a count of seconds and fractions of seconds at
nanosecond resolution. The count is relative to an epoch at UTC midnight on
January 1, 1970, in the proleptic Gregorian calendar which extends the
Gregorian calendar backwards to year one.
Value represents a dynamically typed value which can be either
null, a number, a string, a boolean, a recursive struct value, or a
list of values. A producer of value is expected to set one of these
variants. Absence of any variant indicates an error.
The compressions the client advertises and can decode in responses (accept-encoding and
connect-accept-encoding), so the server may gzip what it sends back. Compressing the request
is a separate opt-in through createConnectTransport.
A SecurityContext without the system roots, carrying RootCertificates.trustedRoots instead.
The pinned set replaces the platform trust store, so it has to cover every CA the backends can
serve, fallback hosts included.
TLS by URI scheme: https and wss get the context pinned to RootCertificates.trustedRoots,
http and ws get plain h2c. Public and pure, so the trust decision is testable without a real
client. connectrpc branches on the same scheme and consults the SecurityContext only for TLS
origins, which is why the shared client below can always carry the pinned context.