Documentation
¶
Index ¶
- func WrapGRPCMetadata(headers metadata.MD) api.HeaderMap
- func WrapGRPCRequest(target string, method string, header metadata.MD, ...) api.HTTPRequest
- func WrapGRPCResponse(statusCode codes.Code, header metadata.MD, trailer metadata.MD, ...) api.HTTPResponse
- type GRPCDialer
- type GRPCRequest
- func (r *GRPCRequest) Body() io.ReadCloser
- func (r *GRPCRequest) ConnectionState() network.ConnectionState
- func (r *GRPCRequest) ContentLength() int64
- func (r *GRPCRequest) Context() context.Context
- func (r *GRPCRequest) HTTPProtocol() string
- func (r *GRPCRequest) Header() api.HeaderMap
- func (r *GRPCRequest) Host() string
- func (r *GRPCRequest) Method() string
- func (r *GRPCRequest) RemoteAddr() string
- func (r *GRPCRequest) SetBody(io.ReadCloser)
- func (r *GRPCRequest) Trailer() api.HeaderMap
- func (r *GRPCRequest) URL() *url.URL
- func (r *GRPCRequest) WithContext(ctx context.Context) api.HTTPRequest
- type GRPCResponse
- func (r *GRPCResponse) Body() io.ReadCloser
- func (r *GRPCResponse) ConnectionState() network.ConnectionState
- func (r *GRPCResponse) ContentLength() int64
- func (r *GRPCResponse) Error() error
- func (r *GRPCResponse) Header() api.HeaderMap
- func (r *GRPCResponse) SetBody(io.ReadCloser)
- func (r *GRPCResponse) StatusCode() int
- func (r *GRPCResponse) Trailer() api.HeaderMap
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func WrapGRPCRequest ¶
func WrapGRPCRequest(target string, method string, header metadata.MD, connectionState network.ConnectionState) api.HTTPRequest
func WrapGRPCResponse ¶
Types ¶
type GRPCDialer ¶
type GRPCDialer struct {
http.MiddlewareHandler
// contains filtered or unexported fields
}
func NewGRPCDialer ¶
func NewGRPCDialer(caClient ca.Client, streamHandler api.StreamHandler, discoveryClient discovery.DiscoveryClient, logger logr.Logger) *GRPCDialer
func (*GRPCDialer) GetTLSConfig ¶
func (g *GRPCDialer) GetTLSConfig() *tls.Config
func (*GRPCDialer) RequestInterceptor ¶
func (g *GRPCDialer) RequestInterceptor(ctx context.Context, method string, req, reply interface{}, cc *grpc.ClientConn, invoker grpc.UnaryInvoker, opts ...grpc.CallOption) error
type GRPCRequest ¶
type GRPCRequest struct {
// contains filtered or unexported fields
}
func (*GRPCRequest) Body ¶
func (r *GRPCRequest) Body() io.ReadCloser
func (*GRPCRequest) ConnectionState ¶
func (r *GRPCRequest) ConnectionState() network.ConnectionState
func (*GRPCRequest) ContentLength ¶
func (r *GRPCRequest) ContentLength() int64
func (*GRPCRequest) Context ¶
func (r *GRPCRequest) Context() context.Context
func (*GRPCRequest) HTTPProtocol ¶
func (r *GRPCRequest) HTTPProtocol() string
func (*GRPCRequest) Header ¶
func (r *GRPCRequest) Header() api.HeaderMap
func (*GRPCRequest) Host ¶
func (r *GRPCRequest) Host() string
func (*GRPCRequest) Method ¶
func (r *GRPCRequest) Method() string
func (*GRPCRequest) RemoteAddr ¶
func (r *GRPCRequest) RemoteAddr() string
func (*GRPCRequest) SetBody ¶
func (r *GRPCRequest) SetBody(io.ReadCloser)
func (*GRPCRequest) Trailer ¶
func (r *GRPCRequest) Trailer() api.HeaderMap
func (*GRPCRequest) URL ¶
func (r *GRPCRequest) URL() *url.URL
func (*GRPCRequest) WithContext ¶
func (r *GRPCRequest) WithContext(ctx context.Context) api.HTTPRequest
type GRPCResponse ¶
type GRPCResponse struct {
// contains filtered or unexported fields
}
func (*GRPCResponse) Body ¶
func (r *GRPCResponse) Body() io.ReadCloser
func (*GRPCResponse) ConnectionState ¶
func (r *GRPCResponse) ConnectionState() network.ConnectionState
func (*GRPCResponse) ContentLength ¶
func (r *GRPCResponse) ContentLength() int64
func (*GRPCResponse) Error ¶
func (r *GRPCResponse) Error() error
func (*GRPCResponse) Header ¶
func (r *GRPCResponse) Header() api.HeaderMap
func (*GRPCResponse) SetBody ¶
func (r *GRPCResponse) SetBody(io.ReadCloser)
func (*GRPCResponse) StatusCode ¶
func (r *GRPCResponse) StatusCode() int
func (*GRPCResponse) Trailer ¶
func (r *GRPCResponse) Trailer() api.HeaderMap
Click to show internal directories.
Click to hide internal directories.