Documentation
¶
Index ¶
- Constants
- func NewStorageServiceHandler(svc StorageServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
- type StorageServiceClient
- type StorageServiceHandler
- type UnimplementedStorageServiceHandler
- func (UnimplementedStorageServiceHandler) GetHealth(context.Context, *connect.Request[v1.GetHealthRequest]) (*connect.Response[v1.GetHealthResponse], error)
- func (UnimplementedStorageServiceHandler) GetIPData(context.Context, *connect.Request[v1.GetIPDataRequest]) (*connect.Response[v1.GetIPDataResponse], error)
- func (UnimplementedStorageServiceHandler) GetRendezvousNodes(context.Context, *connect.Request[v1.GetRendezvousNodesRequest]) (*connect.Response[v1.GetRendezvousNodesResponse], error)
- func (UnimplementedStorageServiceHandler) GetStatus(context.Context, *connect.Request[v1.GetStatusRequest]) (*connect.Response[v1.GetStatusResponse], error)
- func (UnimplementedStorageServiceHandler) GetStreamURL(context.Context, *connect.Request[v1.GetStreamURLRequest]) (*connect.Response[v1.GetStreamURLResponse], error)
- func (UnimplementedStorageServiceHandler) GetUpload(context.Context, *connect.Request[v1.GetUploadRequest]) (*connect.Response[v1.GetUploadResponse], error)
- func (UnimplementedStorageServiceHandler) Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error)
- func (UnimplementedStorageServiceHandler) StreamTrack(context.Context, *connect.Request[v1.StreamTrackRequest], ...) error
- func (UnimplementedStorageServiceHandler) UploadFiles(context.Context, *connect.Request[v1.UploadFilesRequest]) (*connect.Response[v1.UploadFilesResponse], error)
Constants ¶
const ( // StorageServicePingProcedure is the fully-qualified name of the StorageService's Ping RPC. StorageServicePingProcedure = "/storage.v1.StorageService/Ping" // StorageServiceGetHealthProcedure is the fully-qualified name of the StorageService's GetHealth // RPC. StorageServiceGetHealthProcedure = "/storage.v1.StorageService/GetHealth" // StorageServiceUploadFilesProcedure is the fully-qualified name of the StorageService's // UploadFiles RPC. StorageServiceUploadFilesProcedure = "/storage.v1.StorageService/UploadFiles" // StorageServiceGetUploadProcedure is the fully-qualified name of the StorageService's GetUpload // RPC. StorageServiceGetUploadProcedure = "/storage.v1.StorageService/GetUpload" // StorageServiceStreamTrackProcedure is the fully-qualified name of the StorageService's // StreamTrack RPC. StorageServiceStreamTrackProcedure = "/storage.v1.StorageService/StreamTrack" // StorageServiceGetStreamURLProcedure is the fully-qualified name of the StorageService's // GetStreamURL RPC. StorageServiceGetStreamURLProcedure = "/storage.v1.StorageService/GetStreamURL" // StorageServiceGetIPDataProcedure is the fully-qualified name of the StorageService's GetIPData // RPC. StorageServiceGetIPDataProcedure = "/storage.v1.StorageService/GetIPData" // StorageServiceGetRendezvousNodesProcedure is the fully-qualified name of the StorageService's // GetRendezvousNodes RPC. StorageServiceGetRendezvousNodesProcedure = "/storage.v1.StorageService/GetRendezvousNodes" // StorageServiceGetStatusProcedure is the fully-qualified name of the StorageService's GetStatus // RPC. StorageServiceGetStatusProcedure = "/storage.v1.StorageService/GetStatus" )
These constants are the fully-qualified names of the RPCs defined in this package. They're exposed at runtime as Spec.Procedure and as the final two segments of the HTTP route.
Note that these are different from the fully-qualified method names used by google.golang.org/protobuf/reflect/protoreflect. To convert from these constants to reflection-formatted method names, remove the leading slash and convert the remaining slash to a period.
const (
// StorageServiceName is the fully-qualified name of the StorageService service.
StorageServiceName = "storage.v1.StorageService"
)
Variables ¶
This section is empty.
Functions ¶
func NewStorageServiceHandler ¶
func NewStorageServiceHandler(svc StorageServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
NewStorageServiceHandler builds an HTTP handler from the service implementation. It returns the path on which to mount the handler and the handler itself.
By default, handlers support the Connect, gRPC, and gRPC-Web protocols with the binary Protobuf and JSON codecs. They also support gzip compression.
Types ¶
type StorageServiceClient ¶
type StorageServiceClient interface { Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error) GetHealth(context.Context, *connect.Request[v1.GetHealthRequest]) (*connect.Response[v1.GetHealthResponse], error) UploadFiles(context.Context, *connect.Request[v1.UploadFilesRequest]) (*connect.Response[v1.UploadFilesResponse], error) GetUpload(context.Context, *connect.Request[v1.GetUploadRequest]) (*connect.Response[v1.GetUploadResponse], error) StreamTrack(context.Context, *connect.Request[v1.StreamTrackRequest]) (*connect.ServerStreamForClient[v1.StreamTrackResponse], error) GetStreamURL(context.Context, *connect.Request[v1.GetStreamURLRequest]) (*connect.Response[v1.GetStreamURLResponse], error) GetIPData(context.Context, *connect.Request[v1.GetIPDataRequest]) (*connect.Response[v1.GetIPDataResponse], error) GetRendezvousNodes(context.Context, *connect.Request[v1.GetRendezvousNodesRequest]) (*connect.Response[v1.GetRendezvousNodesResponse], error) GetStatus(context.Context, *connect.Request[v1.GetStatusRequest]) (*connect.Response[v1.GetStatusResponse], error) }
StorageServiceClient is a client for the storage.v1.StorageService service.
func NewStorageServiceClient ¶
func NewStorageServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) StorageServiceClient
NewStorageServiceClient constructs a client for the storage.v1.StorageService service. By default, it uses the Connect protocol with the binary Protobuf Codec, asks for gzipped responses, and sends uncompressed requests. To use the gRPC or gRPC-Web protocols, supply the connect.WithGRPC() or connect.WithGRPCWeb() options.
The URL supplied here should be the base URL for the Connect or gRPC server (for example, http://api.acme.com or https://acme.com/grpc).
type StorageServiceHandler ¶
type StorageServiceHandler interface { Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error) GetHealth(context.Context, *connect.Request[v1.GetHealthRequest]) (*connect.Response[v1.GetHealthResponse], error) UploadFiles(context.Context, *connect.Request[v1.UploadFilesRequest]) (*connect.Response[v1.UploadFilesResponse], error) GetUpload(context.Context, *connect.Request[v1.GetUploadRequest]) (*connect.Response[v1.GetUploadResponse], error) StreamTrack(context.Context, *connect.Request[v1.StreamTrackRequest], *connect.ServerStream[v1.StreamTrackResponse]) error GetStreamURL(context.Context, *connect.Request[v1.GetStreamURLRequest]) (*connect.Response[v1.GetStreamURLResponse], error) GetIPData(context.Context, *connect.Request[v1.GetIPDataRequest]) (*connect.Response[v1.GetIPDataResponse], error) GetRendezvousNodes(context.Context, *connect.Request[v1.GetRendezvousNodesRequest]) (*connect.Response[v1.GetRendezvousNodesResponse], error) GetStatus(context.Context, *connect.Request[v1.GetStatusRequest]) (*connect.Response[v1.GetStatusResponse], error) }
StorageServiceHandler is an implementation of the storage.v1.StorageService service.
type UnimplementedStorageServiceHandler ¶
type UnimplementedStorageServiceHandler struct{}
UnimplementedStorageServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedStorageServiceHandler) GetHealth ¶
func (UnimplementedStorageServiceHandler) GetHealth(context.Context, *connect.Request[v1.GetHealthRequest]) (*connect.Response[v1.GetHealthResponse], error)
func (UnimplementedStorageServiceHandler) GetIPData ¶
func (UnimplementedStorageServiceHandler) GetIPData(context.Context, *connect.Request[v1.GetIPDataRequest]) (*connect.Response[v1.GetIPDataResponse], error)
func (UnimplementedStorageServiceHandler) GetRendezvousNodes ¶
func (UnimplementedStorageServiceHandler) GetRendezvousNodes(context.Context, *connect.Request[v1.GetRendezvousNodesRequest]) (*connect.Response[v1.GetRendezvousNodesResponse], error)
func (UnimplementedStorageServiceHandler) GetStatus ¶
func (UnimplementedStorageServiceHandler) GetStatus(context.Context, *connect.Request[v1.GetStatusRequest]) (*connect.Response[v1.GetStatusResponse], error)
func (UnimplementedStorageServiceHandler) GetStreamURL ¶
func (UnimplementedStorageServiceHandler) GetStreamURL(context.Context, *connect.Request[v1.GetStreamURLRequest]) (*connect.Response[v1.GetStreamURLResponse], error)
func (UnimplementedStorageServiceHandler) GetUpload ¶
func (UnimplementedStorageServiceHandler) GetUpload(context.Context, *connect.Request[v1.GetUploadRequest]) (*connect.Response[v1.GetUploadResponse], error)
func (UnimplementedStorageServiceHandler) Ping ¶
func (UnimplementedStorageServiceHandler) Ping(context.Context, *connect.Request[v1.PingRequest]) (*connect.Response[v1.PingResponse], error)
func (UnimplementedStorageServiceHandler) StreamTrack ¶
func (UnimplementedStorageServiceHandler) StreamTrack(context.Context, *connect.Request[v1.StreamTrackRequest], *connect.ServerStream[v1.StreamTrackResponse]) error
func (UnimplementedStorageServiceHandler) UploadFiles ¶
func (UnimplementedStorageServiceHandler) UploadFiles(context.Context, *connect.Request[v1.UploadFilesRequest]) (*connect.Response[v1.UploadFilesResponse], error)