postgres

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Apr 16, 2025 License: Apache-2.0 Imports: 9 Imported by: 2

Documentation

Index

Constants

View Source
const (
	Postgres_GetCapabilities_FullMethodName     = "/cnpgi.identity.v1.Postgres/GetCapabilities"
	Postgres_EnrichConfiguration_FullMethodName = "/cnpgi.identity.v1.Postgres/EnrichConfiguration"
)

Variables

View Source
var (
	PostgresCapability_RPC_Type_name = map[int32]string{
		0: "TYPE_UNSPECIFIED",
		1: "TYPE_ENRICH_CONFIGURATION",
	}
	PostgresCapability_RPC_Type_value = map[string]int32{
		"TYPE_UNSPECIFIED":          0,
		"TYPE_ENRICH_CONFIGURATION": 1,
	}
)

Enum value maps for PostgresCapability_RPC_Type.

View Source
var File_proto_postgres_proto protoreflect.FileDescriptor
View Source
var Postgres_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "cnpgi.identity.v1.Postgres",
	HandlerType: (*PostgresServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "GetCapabilities",
			Handler:    _Postgres_GetCapabilities_Handler,
		},
		{
			MethodName: "EnrichConfiguration",
			Handler:    _Postgres_EnrichConfiguration_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "proto/postgres.proto",
}

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

Functions

func RegisterPostgresServer

func RegisterPostgresServer(s grpc.ServiceRegistrar, srv PostgresServer)

Types

type EnrichConfigurationRequest

type EnrichConfigurationRequest struct {

	// This field is REQUIRED and represent the PostgreSQL configuration parameters as
	// generated by the instance manager
	Configs map[string]string `` /* 141-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*EnrichConfigurationRequest) Descriptor deprecated

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

Deprecated: Use EnrichConfigurationRequest.ProtoReflect.Descriptor instead.

func (*EnrichConfigurationRequest) GetConfigs

func (x *EnrichConfigurationRequest) GetConfigs() map[string]string

func (*EnrichConfigurationRequest) ProtoMessage

func (*EnrichConfigurationRequest) ProtoMessage()

func (*EnrichConfigurationRequest) ProtoReflect

func (*EnrichConfigurationRequest) Reset

func (x *EnrichConfigurationRequest) Reset()

func (*EnrichConfigurationRequest) String

func (x *EnrichConfigurationRequest) String() string

type EnrichConfigurationResult

type EnrichConfigurationResult struct {

	// This field is OPTIONAL. It represent the configuration parameters that need
	// to be changed before applying a new configuration
	Configs map[string]string `` /* 141-byte string literal not displayed */
	// contains filtered or unexported fields
}

func (*EnrichConfigurationResult) Descriptor deprecated

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

Deprecated: Use EnrichConfigurationResult.ProtoReflect.Descriptor instead.

func (*EnrichConfigurationResult) GetConfigs

func (x *EnrichConfigurationResult) GetConfigs() map[string]string

func (*EnrichConfigurationResult) ProtoMessage

func (*EnrichConfigurationResult) ProtoMessage()

func (*EnrichConfigurationResult) ProtoReflect

func (*EnrichConfigurationResult) Reset

func (x *EnrichConfigurationResult) Reset()

func (*EnrichConfigurationResult) String

func (x *EnrichConfigurationResult) String() string

type PostgresCapabilitiesRequest

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

func (*PostgresCapabilitiesRequest) Descriptor deprecated

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

Deprecated: Use PostgresCapabilitiesRequest.ProtoReflect.Descriptor instead.

func (*PostgresCapabilitiesRequest) ProtoMessage

func (*PostgresCapabilitiesRequest) ProtoMessage()

func (*PostgresCapabilitiesRequest) ProtoReflect

func (*PostgresCapabilitiesRequest) Reset

func (x *PostgresCapabilitiesRequest) Reset()

func (*PostgresCapabilitiesRequest) String

func (x *PostgresCapabilitiesRequest) String() string

type PostgresCapabilitiesResult

type PostgresCapabilitiesResult struct {

	// All the capabilities that the controller service supports. This
	// field is OPTIONAL.
	Capabilities []*PostgresCapability `protobuf:"bytes,1,rep,name=capabilities,proto3" json:"capabilities,omitempty"`
	// contains filtered or unexported fields
}

func (*PostgresCapabilitiesResult) Descriptor deprecated

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

Deprecated: Use PostgresCapabilitiesResult.ProtoReflect.Descriptor instead.

func (*PostgresCapabilitiesResult) GetCapabilities

func (x *PostgresCapabilitiesResult) GetCapabilities() []*PostgresCapability

func (*PostgresCapabilitiesResult) ProtoMessage

func (*PostgresCapabilitiesResult) ProtoMessage()

func (*PostgresCapabilitiesResult) ProtoReflect

func (*PostgresCapabilitiesResult) Reset

func (x *PostgresCapabilitiesResult) Reset()

func (*PostgresCapabilitiesResult) String

func (x *PostgresCapabilitiesResult) String() string

type PostgresCapability

type PostgresCapability struct {

	// Types that are valid to be assigned to Type:
	//
	//	*PostgresCapability_Rpc
	Type isPostgresCapability_Type `protobuf_oneof:"type"`
	// contains filtered or unexported fields
}

func (*PostgresCapability) Descriptor deprecated

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

Deprecated: Use PostgresCapability.ProtoReflect.Descriptor instead.

func (*PostgresCapability) GetRpc

func (*PostgresCapability) GetType

func (x *PostgresCapability) GetType() isPostgresCapability_Type

func (*PostgresCapability) ProtoMessage

func (*PostgresCapability) ProtoMessage()

func (*PostgresCapability) ProtoReflect

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

func (*PostgresCapability) Reset

func (x *PostgresCapability) Reset()

func (*PostgresCapability) String

func (x *PostgresCapability) String() string

type PostgresCapability_RPC

type PostgresCapability_RPC struct {
	Type PostgresCapability_RPC_Type `protobuf:"varint,1,opt,name=type,proto3,enum=cnpgi.identity.v1.PostgresCapability_RPC_Type" json:"type,omitempty"`
	// contains filtered or unexported fields
}

func (*PostgresCapability_RPC) Descriptor deprecated

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

Deprecated: Use PostgresCapability_RPC.ProtoReflect.Descriptor instead.

func (*PostgresCapability_RPC) GetType

func (*PostgresCapability_RPC) ProtoMessage

func (*PostgresCapability_RPC) ProtoMessage()

func (*PostgresCapability_RPC) ProtoReflect

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

func (*PostgresCapability_RPC) Reset

func (x *PostgresCapability_RPC) Reset()

func (*PostgresCapability_RPC) String

func (x *PostgresCapability_RPC) String() string

type PostgresCapability_RPC_Type

type PostgresCapability_RPC_Type int32
const (
	PostgresCapability_RPC_TYPE_UNSPECIFIED PostgresCapability_RPC_Type = 0
	// TYPE_BACKUP indicates that the Plugin is able to
	// enrich the PostgreSQL configuration via the
	// EnrichConfiguration endpoint
	PostgresCapability_RPC_TYPE_ENRICH_CONFIGURATION PostgresCapability_RPC_Type = 1
)

func (PostgresCapability_RPC_Type) Descriptor

func (PostgresCapability_RPC_Type) Enum

func (PostgresCapability_RPC_Type) EnumDescriptor deprecated

func (PostgresCapability_RPC_Type) EnumDescriptor() ([]byte, []int)

Deprecated: Use PostgresCapability_RPC_Type.Descriptor instead.

func (PostgresCapability_RPC_Type) Number

func (PostgresCapability_RPC_Type) String

func (PostgresCapability_RPC_Type) Type

type PostgresCapability_Rpc

type PostgresCapability_Rpc struct {
	Rpc *PostgresCapability_RPC `protobuf:"bytes,1,opt,name=rpc,proto3,oneof"`
}

type PostgresClient

type PostgresClient interface {
	// GetCapabilities gets the capabilities of the Backup service
	GetCapabilities(ctx context.Context, in *PostgresCapabilitiesRequest, opts ...grpc.CallOption) (*PostgresCapabilitiesResult, error)
	// EnrichConfiguration is called before applying the configuration
	// to PostgreSQL
	EnrichConfiguration(ctx context.Context, in *EnrichConfigurationRequest, opts ...grpc.CallOption) (*EnrichConfigurationResult, error)
}

PostgresClient is the client API for Postgres 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 NewPostgresClient

func NewPostgresClient(cc grpc.ClientConnInterface) PostgresClient

type PostgresServer

type PostgresServer interface {
	// GetCapabilities gets the capabilities of the Backup service
	GetCapabilities(context.Context, *PostgresCapabilitiesRequest) (*PostgresCapabilitiesResult, error)
	// EnrichConfiguration is called before applying the configuration
	// to PostgreSQL
	EnrichConfiguration(context.Context, *EnrichConfigurationRequest) (*EnrichConfigurationResult, error)
	// contains filtered or unexported methods
}

PostgresServer is the server API for Postgres service. All implementations must embed UnimplementedPostgresServer for forward compatibility.

type UnimplementedPostgresServer

type UnimplementedPostgresServer struct{}

UnimplementedPostgresServer must be embedded to have forward compatible implementations.

NOTE: this should be embedded by value instead of pointer to avoid a nil pointer dereference when methods are called.

type UnsafePostgresServer

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

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

Jump to

Keyboard shortcuts

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