MCPcopy
hub / github.com/grpc-ecosystem/grpc-gateway / WithWriteContentLength

Function WithWriteContentLength

runtime/mux.go:289–293  ·  view source on GitHub ↗

WithWriteContentLength returns a ServeMuxOption to enable writing content length on non-streaming responses

()

Source from the content-addressed store, hash-verified

287
288// WithWriteContentLength returns a ServeMuxOption to enable writing content length on non-streaming responses
289func WithWriteContentLength() ServeMuxOption {
290 return func(serveMux *ServeMux) {
291 serveMux.writeContentLength = true
292 }
293}
294
295// WithHealthEndpointAt returns a ServeMuxOption that will add an endpoint to the created ServeMux at the path specified by endpointPath.
296// When called the handler will forward the request to the upstream grpc service health check (defined in the

Calls

no outgoing calls