Documentation
¶
Index ¶
- Constants
- func NewKv2ServiceHandler(svc Kv2ServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
- type Kv2ServiceClient
- type Kv2ServiceHandler
- type UnimplementedKv2ServiceHandler
- func (UnimplementedKv2ServiceHandler) ApplicationVersionInfo(context.Context, *connect.Request[v1.ApplicationVersionInfoRequest]) (*connect.Response[v1.ApplicationVersionInfoResponse], error)
- func (UnimplementedKv2ServiceHandler) Backup(context.Context, *connect.Request[v1.BackupRequest]) (*connect.Response[v1.BackupResponse], error)
- func (UnimplementedKv2ServiceHandler) CreateSecret(context.Context, *connect.Request[v1.CreateSecretRequest]) (*connect.Response[v1.CreateSecretResponse], error)
- func (UnimplementedKv2ServiceHandler) DeleteSecret(context.Context, *connect.Request[v1.DeleteSecretRequest]) (*connect.Response[v1.DeleteSecretResponse], error)
- func (UnimplementedKv2ServiceHandler) GetSecret(context.Context, *connect.Request[v1.GetSecretRequest]) (*connect.Response[v1.GetSecretResponse], error)
- func (UnimplementedKv2ServiceHandler) ListSecrets(context.Context, *connect.Request[v1.ListSecretsRequest]) (*connect.Response[v1.ListSecretsResponse], error)
- func (UnimplementedKv2ServiceHandler) RevertSecret(context.Context, *connect.Request[v1.RevertSecretRequest]) (*connect.Response[v1.RevertSecretResponse], error)
- func (UnimplementedKv2ServiceHandler) UpdateSecret(context.Context, *connect.Request[v1.UpdateSecretRequest]) (*connect.Response[v1.UpdateSecretResponse], error)
Constants ¶
const ( // Kv2ServiceCreateSecretProcedure is the fully-qualified name of the Kv2Service's CreateSecret RPC. Kv2ServiceCreateSecretProcedure = "/secrets.v1.Kv2Service/CreateSecret" // Kv2ServiceGetSecretProcedure is the fully-qualified name of the Kv2Service's GetSecret RPC. Kv2ServiceGetSecretProcedure = "/secrets.v1.Kv2Service/GetSecret" // Kv2ServiceUpdateSecretProcedure is the fully-qualified name of the Kv2Service's UpdateSecret RPC. Kv2ServiceUpdateSecretProcedure = "/secrets.v1.Kv2Service/UpdateSecret" // Kv2ServiceDeleteSecretProcedure is the fully-qualified name of the Kv2Service's DeleteSecret RPC. Kv2ServiceDeleteSecretProcedure = "/secrets.v1.Kv2Service/DeleteSecret" // Kv2ServiceRevertSecretProcedure is the fully-qualified name of the Kv2Service's RevertSecret RPC. Kv2ServiceRevertSecretProcedure = "/secrets.v1.Kv2Service/RevertSecret" // Kv2ServiceListSecretsProcedure is the fully-qualified name of the Kv2Service's ListSecrets RPC. Kv2ServiceListSecretsProcedure = "/secrets.v1.Kv2Service/ListSecrets" // Kv2ServiceBackupProcedure is the fully-qualified name of the Kv2Service's Backup RPC. Kv2ServiceBackupProcedure = "/secrets.v1.Kv2Service/Backup" // Kv2ServiceApplicationVersionInfoProcedure is the fully-qualified name of the Kv2Service's // ApplicationVersionInfo RPC. Kv2ServiceApplicationVersionInfoProcedure = "/secrets.v1.Kv2Service/ApplicationVersionInfo" )
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 (
// Kv2ServiceName is the fully-qualified name of the Kv2Service service.
Kv2ServiceName = "secrets.v1.Kv2Service"
)
Variables ¶
This section is empty.
Functions ¶
func NewKv2ServiceHandler ¶
func NewKv2ServiceHandler(svc Kv2ServiceHandler, opts ...connect.HandlerOption) (string, http.Handler)
NewKv2ServiceHandler 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 Kv2ServiceClient ¶
type Kv2ServiceClient interface { CreateSecret(context.Context, *connect.Request[v1.CreateSecretRequest]) (*connect.Response[v1.CreateSecretResponse], error) GetSecret(context.Context, *connect.Request[v1.GetSecretRequest]) (*connect.Response[v1.GetSecretResponse], error) UpdateSecret(context.Context, *connect.Request[v1.UpdateSecretRequest]) (*connect.Response[v1.UpdateSecretResponse], error) DeleteSecret(context.Context, *connect.Request[v1.DeleteSecretRequest]) (*connect.Response[v1.DeleteSecretResponse], error) RevertSecret(context.Context, *connect.Request[v1.RevertSecretRequest]) (*connect.Response[v1.RevertSecretResponse], error) ListSecrets(context.Context, *connect.Request[v1.ListSecretsRequest]) (*connect.Response[v1.ListSecretsResponse], error) Backup(context.Context, *connect.Request[v1.BackupRequest]) (*connect.Response[v1.BackupResponse], error) ApplicationVersionInfo(context.Context, *connect.Request[v1.ApplicationVersionInfoRequest]) (*connect.Response[v1.ApplicationVersionInfoResponse], error) }
Kv2ServiceClient is a client for the secrets.v1.Kv2Service service.
func NewKv2ServiceClient ¶
func NewKv2ServiceClient(httpClient connect.HTTPClient, baseURL string, opts ...connect.ClientOption) Kv2ServiceClient
NewKv2ServiceClient constructs a client for the secrets.v1.Kv2Service 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 Kv2ServiceHandler ¶
type Kv2ServiceHandler interface { CreateSecret(context.Context, *connect.Request[v1.CreateSecretRequest]) (*connect.Response[v1.CreateSecretResponse], error) GetSecret(context.Context, *connect.Request[v1.GetSecretRequest]) (*connect.Response[v1.GetSecretResponse], error) UpdateSecret(context.Context, *connect.Request[v1.UpdateSecretRequest]) (*connect.Response[v1.UpdateSecretResponse], error) DeleteSecret(context.Context, *connect.Request[v1.DeleteSecretRequest]) (*connect.Response[v1.DeleteSecretResponse], error) RevertSecret(context.Context, *connect.Request[v1.RevertSecretRequest]) (*connect.Response[v1.RevertSecretResponse], error) ListSecrets(context.Context, *connect.Request[v1.ListSecretsRequest]) (*connect.Response[v1.ListSecretsResponse], error) Backup(context.Context, *connect.Request[v1.BackupRequest]) (*connect.Response[v1.BackupResponse], error) ApplicationVersionInfo(context.Context, *connect.Request[v1.ApplicationVersionInfoRequest]) (*connect.Response[v1.ApplicationVersionInfoResponse], error) }
Kv2ServiceHandler is an implementation of the secrets.v1.Kv2Service service.
type UnimplementedKv2ServiceHandler ¶
type UnimplementedKv2ServiceHandler struct{}
UnimplementedKv2ServiceHandler returns CodeUnimplemented from all methods.
func (UnimplementedKv2ServiceHandler) ApplicationVersionInfo ¶ added in v0.11.0
func (UnimplementedKv2ServiceHandler) ApplicationVersionInfo(context.Context, *connect.Request[v1.ApplicationVersionInfoRequest]) (*connect.Response[v1.ApplicationVersionInfoResponse], error)
func (UnimplementedKv2ServiceHandler) Backup ¶
func (UnimplementedKv2ServiceHandler) Backup(context.Context, *connect.Request[v1.BackupRequest]) (*connect.Response[v1.BackupResponse], error)
func (UnimplementedKv2ServiceHandler) CreateSecret ¶
func (UnimplementedKv2ServiceHandler) CreateSecret(context.Context, *connect.Request[v1.CreateSecretRequest]) (*connect.Response[v1.CreateSecretResponse], error)
func (UnimplementedKv2ServiceHandler) DeleteSecret ¶
func (UnimplementedKv2ServiceHandler) DeleteSecret(context.Context, *connect.Request[v1.DeleteSecretRequest]) (*connect.Response[v1.DeleteSecretResponse], error)
func (UnimplementedKv2ServiceHandler) GetSecret ¶
func (UnimplementedKv2ServiceHandler) GetSecret(context.Context, *connect.Request[v1.GetSecretRequest]) (*connect.Response[v1.GetSecretResponse], error)
func (UnimplementedKv2ServiceHandler) ListSecrets ¶
func (UnimplementedKv2ServiceHandler) ListSecrets(context.Context, *connect.Request[v1.ListSecretsRequest]) (*connect.Response[v1.ListSecretsResponse], error)
func (UnimplementedKv2ServiceHandler) RevertSecret ¶
func (UnimplementedKv2ServiceHandler) RevertSecret(context.Context, *connect.Request[v1.RevertSecretRequest]) (*connect.Response[v1.RevertSecretResponse], error)
func (UnimplementedKv2ServiceHandler) UpdateSecret ¶
func (UnimplementedKv2ServiceHandler) UpdateSecret(context.Context, *connect.Request[v1.UpdateSecretRequest]) (*connect.Response[v1.UpdateSecretResponse], error)