grpcapi

package module
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 30, 2026 License: Apache-2.0 Imports: 9 Imported by: 0

README

gRPC API

Generated Go types and gRPC client/server interfaces for the cloud-secrets Controller and Secrets APIs.

import grpcapi "github.com/swarm-deploy/cloud-secrets/pkg/grpc-api"

The source protobuf definition lives in api/swarm_deploy/cloud_secrets/controller.proto. Generated .pb.go files should not be edited manually.

Documentation

Index

Constants

View Source
const (
	Controller_GetInfo_FullMethodName = "/swarm_deploy.cloud_secrets.Controller/GetInfo"
	Controller_Sync_FullMethodName    = "/swarm_deploy.cloud_secrets.Controller/Sync"
)
View Source
const (
	Secrets_Create_FullMethodName = "/swarm_deploy.cloud_secrets.Secrets/Create"
)

Variables

View Source
var Controller_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "swarm_deploy.cloud_secrets.Controller",
	HandlerType: (*ControllerServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetInfo",
			Handler:    _Controller_GetInfo_Handler,
		},
		{
			MethodName: "Sync",
			Handler:    _Controller_Sync_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "swarm_deploy/cloud_secrets/controller.proto",
}

Controller_ServiceDesc is the grpc.ServiceDesc for Controller service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

View Source
var File_swarm_deploy_cloud_secrets_controller_proto protoreflect.FileDescriptor
View Source
var Secrets_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "swarm_deploy.cloud_secrets.Secrets",
	HandlerType: (*SecretsServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "Create",
			Handler:    _Secrets_Create_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "swarm_deploy/cloud_secrets/controller.proto",
}

Secrets_ServiceDesc is the grpc.ServiceDesc for Secrets service. It's only intended for direct use with grpc.RegisterService, and not to be introspected or modified (even as a copy)

Functions

func RegisterControllerServer

func RegisterControllerServer(s grpc.ServiceRegistrar, srv ControllerServer)

func RegisterSecretsServer added in v0.1.1

func RegisterSecretsServer(s grpc.ServiceRegistrar, srv SecretsServer)

Types

type ControllerClient

type ControllerClient interface {
	GetInfo(ctx context.Context, in *GetInfoRequest, opts ...grpc.CallOption) (*GetInfoResponse, error)
	Sync(ctx context.Context, in *SyncRequest, opts ...grpc.CallOption) (*SyncResponse, error)
}

ControllerClient is the client API for Controller service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewControllerClient

func NewControllerClient(cc grpc.ClientConnInterface) ControllerClient

type ControllerServer

type ControllerServer interface {
	GetInfo(context.Context, *GetInfoRequest) (*GetInfoResponse, error)
	Sync(context.Context, *SyncRequest) (*SyncResponse, error)
	// contains filtered or unexported methods
}

ControllerServer is the server API for Controller service. All implementations must embed UnimplementedControllerServer for forward compatibility

type CreateSecretRequest added in v0.1.1

type CreateSecretRequest struct {
	Path        string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	Value       []byte `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	Key         string `protobuf:"bytes,3,opt,name=key,proto3" json:"key,omitempty"`
	Description string `protobuf:"bytes,4,opt,name=description,proto3" json:"description,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateSecretRequest) Descriptor deprecated added in v0.1.1

func (*CreateSecretRequest) Descriptor() ([]byte, []int)

Deprecated: Use CreateSecretRequest.ProtoReflect.Descriptor instead.

func (*CreateSecretRequest) GetDescription added in v0.1.1

func (x *CreateSecretRequest) GetDescription() string

func (*CreateSecretRequest) GetKey added in v0.1.1

func (x *CreateSecretRequest) GetKey() string

func (*CreateSecretRequest) GetPath added in v0.1.1

func (x *CreateSecretRequest) GetPath() string

func (*CreateSecretRequest) GetValue added in v0.1.1

func (x *CreateSecretRequest) GetValue() []byte

func (*CreateSecretRequest) ProtoMessage added in v0.1.1

func (*CreateSecretRequest) ProtoMessage()

func (*CreateSecretRequest) ProtoReflect added in v0.1.1

func (x *CreateSecretRequest) ProtoReflect() protoreflect.Message

func (*CreateSecretRequest) Reset added in v0.1.1

func (x *CreateSecretRequest) Reset()

func (*CreateSecretRequest) String added in v0.1.1

func (x *CreateSecretRequest) String() string

type CreateSecretResponse added in v0.1.1

type CreateSecretResponse struct {
	Path       string  `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	ManagerUrl *string `protobuf:"bytes,2,opt,name=manager_url,json=managerUrl,proto3,oneof" json:"manager_url,omitempty"`
	// contains filtered or unexported fields
}

func (*CreateSecretResponse) Descriptor deprecated added in v0.1.1

func (*CreateSecretResponse) Descriptor() ([]byte, []int)

Deprecated: Use CreateSecretResponse.ProtoReflect.Descriptor instead.

func (*CreateSecretResponse) GetManagerUrl added in v0.1.1

func (x *CreateSecretResponse) GetManagerUrl() string

func (*CreateSecretResponse) GetPath added in v0.1.1

func (x *CreateSecretResponse) GetPath() string

func (*CreateSecretResponse) ProtoMessage added in v0.1.1

func (*CreateSecretResponse) ProtoMessage()

func (*CreateSecretResponse) ProtoReflect added in v0.1.1

func (x *CreateSecretResponse) ProtoReflect() protoreflect.Message

func (*CreateSecretResponse) Reset added in v0.1.1

func (x *CreateSecretResponse) Reset()

func (*CreateSecretResponse) String added in v0.1.1

func (x *CreateSecretResponse) String() string

type GetInfoRequest

type GetInfoRequest struct {
	// contains filtered or unexported fields
}

func (*GetInfoRequest) Descriptor deprecated

func (*GetInfoRequest) Descriptor() ([]byte, []int)

Deprecated: Use GetInfoRequest.ProtoReflect.Descriptor instead.

func (*GetInfoRequest) ProtoMessage

func (*GetInfoRequest) ProtoMessage()

func (*GetInfoRequest) ProtoReflect

func (x *GetInfoRequest) ProtoReflect() protoreflect.Message

func (*GetInfoRequest) Reset

func (x *GetInfoRequest) Reset()

func (*GetInfoRequest) String

func (x *GetInfoRequest) String() string

type GetInfoResponse

type GetInfoResponse struct {
	Version    string                 `protobuf:"bytes,1,opt,name=version,proto3" json:"version,omitempty"`
	Provider   *Provider              `protobuf:"bytes,2,opt,name=provider,proto3" json:"provider,omitempty"`
	LastSyncAt *timestamppb.Timestamp `protobuf:"bytes,3,opt,name=last_sync_at,json=lastSyncAt,proto3" json:"last_sync_at,omitempty"`
	NextSyncAt *timestamppb.Timestamp `protobuf:"bytes,4,opt,name=next_sync_at,json=nextSyncAt,proto3" json:"next_sync_at,omitempty"`
	// contains filtered or unexported fields
}

func (*GetInfoResponse) Descriptor deprecated

func (*GetInfoResponse) Descriptor() ([]byte, []int)

Deprecated: Use GetInfoResponse.ProtoReflect.Descriptor instead.

func (*GetInfoResponse) GetLastSyncAt

func (x *GetInfoResponse) GetLastSyncAt() *timestamppb.Timestamp

func (*GetInfoResponse) GetNextSyncAt

func (x *GetInfoResponse) GetNextSyncAt() *timestamppb.Timestamp

func (*GetInfoResponse) GetProvider

func (x *GetInfoResponse) GetProvider() *Provider

func (*GetInfoResponse) GetVersion

func (x *GetInfoResponse) GetVersion() string

func (*GetInfoResponse) ProtoMessage

func (*GetInfoResponse) ProtoMessage()

func (*GetInfoResponse) ProtoReflect

func (x *GetInfoResponse) ProtoReflect() protoreflect.Message

func (*GetInfoResponse) Reset

func (x *GetInfoResponse) Reset()

func (*GetInfoResponse) String

func (x *GetInfoResponse) String() string
type Links struct {
	Doc     string `protobuf:"bytes,1,opt,name=doc,proto3" json:"doc,omitempty"`
	Manager string `protobuf:"bytes,2,opt,name=manager,proto3" json:"manager,omitempty"`
	// contains filtered or unexported fields
}

func (*Links) Descriptor deprecated

func (*Links) Descriptor() ([]byte, []int)

Deprecated: Use Links.ProtoReflect.Descriptor instead.

func (*Links) GetDoc

func (x *Links) GetDoc() string

func (*Links) GetManager

func (x *Links) GetManager() string

func (*Links) ProtoMessage

func (*Links) ProtoMessage()

func (*Links) ProtoReflect

func (x *Links) ProtoReflect() protoreflect.Message

func (*Links) Reset

func (x *Links) Reset()

func (*Links) String

func (x *Links) String() string

type Provider

type Provider struct {
	Name  string `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Links *Links `protobuf:"bytes,2,opt,name=links,proto3" json:"links,omitempty"`
	// contains filtered or unexported fields
}

func (*Provider) Descriptor deprecated

func (*Provider) Descriptor() ([]byte, []int)

Deprecated: Use Provider.ProtoReflect.Descriptor instead.

func (x *Provider) GetLinks() *Links

func (*Provider) GetName

func (x *Provider) GetName() string

func (*Provider) ProtoMessage

func (*Provider) ProtoMessage()

func (*Provider) ProtoReflect

func (x *Provider) ProtoReflect() protoreflect.Message

func (*Provider) Reset

func (x *Provider) Reset()

func (*Provider) String

func (x *Provider) String() string

type SecretsClient added in v0.1.1

type SecretsClient interface {
	Create(ctx context.Context, in *CreateSecretRequest, opts ...grpc.CallOption) (*CreateSecretResponse, error)
}

SecretsClient is the client API for Secrets service.

For semantics around ctx use and closing/ending streaming RPCs, please refer to https://pkg.go.dev/google.golang.org/grpc/?tab=doc#ClientConn.NewStream.

func NewSecretsClient added in v0.1.1

func NewSecretsClient(cc grpc.ClientConnInterface) SecretsClient

type SecretsServer added in v0.1.1

type SecretsServer interface {
	Create(context.Context, *CreateSecretRequest) (*CreateSecretResponse, error)
	// contains filtered or unexported methods
}

SecretsServer is the server API for Secrets service. All implementations must embed UnimplementedSecretsServer for forward compatibility

type SyncRequest

type SyncRequest struct {
	// contains filtered or unexported fields
}

func (*SyncRequest) Descriptor deprecated

func (*SyncRequest) Descriptor() ([]byte, []int)

Deprecated: Use SyncRequest.ProtoReflect.Descriptor instead.

func (*SyncRequest) ProtoMessage

func (*SyncRequest) ProtoMessage()

func (*SyncRequest) ProtoReflect

func (x *SyncRequest) ProtoReflect() protoreflect.Message

func (*SyncRequest) Reset

func (x *SyncRequest) Reset()

func (*SyncRequest) String

func (x *SyncRequest) String() string

type SyncResponse

type SyncResponse struct {
	Created   uint32 `protobuf:"varint,1,opt,name=created,proto3" json:"created,omitempty"`
	Updated   uint32 `protobuf:"varint,2,opt,name=updated,proto3" json:"updated,omitempty"`
	Removed   uint32 `protobuf:"varint,3,opt,name=removed,proto3" json:"removed,omitempty"`
	Unchanged uint32 `protobuf:"varint,4,opt,name=unchanged,proto3" json:"unchanged,omitempty"`
	// contains filtered or unexported fields
}

func (*SyncResponse) Descriptor deprecated

func (*SyncResponse) Descriptor() ([]byte, []int)

Deprecated: Use SyncResponse.ProtoReflect.Descriptor instead.

func (*SyncResponse) GetCreated

func (x *SyncResponse) GetCreated() uint32

func (*SyncResponse) GetRemoved

func (x *SyncResponse) GetRemoved() uint32

func (*SyncResponse) GetUnchanged

func (x *SyncResponse) GetUnchanged() uint32

func (*SyncResponse) GetUpdated

func (x *SyncResponse) GetUpdated() uint32

func (*SyncResponse) ProtoMessage

func (*SyncResponse) ProtoMessage()

func (*SyncResponse) ProtoReflect

func (x *SyncResponse) ProtoReflect() protoreflect.Message

func (*SyncResponse) Reset

func (x *SyncResponse) Reset()

func (*SyncResponse) String

func (x *SyncResponse) String() string

type UnimplementedControllerServer

type UnimplementedControllerServer struct {
}

UnimplementedControllerServer must be embedded to have forward compatible implementations.

func (UnimplementedControllerServer) GetInfo

func (UnimplementedControllerServer) Sync

type UnimplementedSecretsServer added in v0.1.1

type UnimplementedSecretsServer struct {
}

UnimplementedSecretsServer must be embedded to have forward compatible implementations.

func (UnimplementedSecretsServer) Create added in v0.1.1

type UnsafeControllerServer

type UnsafeControllerServer interface {
	// contains filtered or unexported methods
}

UnsafeControllerServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to ControllerServer will result in compilation errors.

type UnsafeSecretsServer added in v0.1.1

type UnsafeSecretsServer interface {
	// contains filtered or unexported methods
}

UnsafeSecretsServer may be embedded to opt out of forward compatibility for this service. Use of this interface is not recommended, as added methods to SecretsServer will result in compilation errors.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL