package
0.0.0-20230728070032-dd9e68f319d5
Repository: https://github.com/weaveworks/common.git
Documentation: pkg.go.dev

# README

What? Embedding HTTP requests and responses into a gRPC service; a service and client to translate back and forth between the two, so you can use them with your preferred mux.

Why? Get all the goodness of protobuf encoding, HTTP/2, snappy, load balancing, persistent connection and native Kubernetes load balancing with ~none of the effort.

To rebuild generated protobuf code, run:

protoc -I ./ --go_out=plugins=grpc:./ ./httpgrpc.proto

Follow the instructions here to get a working protoc: https://github.com/gogo/protobuf

# Packages

No description provided by the author

# Functions

Errorf returns a HTTP gRPC error than is correctly forwarded over gRPC, and can eventually be converted back to a HTTP response with HTTPResponseFromError.
ErrorFromHTTPResponse converts an HTTP response into a grpc error.
HTTPResponseFromError converts a grpc error into an HTTP response.
No description provided by the author
No description provided by the author

# Variables

No description provided by the author
No description provided by the author
No description provided by the author

# Structs

No description provided by the author
No description provided by the author
No description provided by the author
UnimplementedHTTPServer can be embedded to have forward compatible implementations.

# Interfaces

HTTPClient is the client API for HTTP service.
HTTPServer is the server API for HTTP service.