postgresql

package
v1.1.0 Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2025 License: Apache-2.0 Imports: 25 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	LogicalBackupMode_name = map[int32]string{
		0: "Full",
		1: "Database",
		2: "Table",
	}
	LogicalBackupMode_value = map[string]int32{
		"Full":     0,
		"Database": 1,
		"Table":    2,
	}
)

Enum value maps for LogicalBackupMode.

View Source
var File_pkg_agent_app_postgresql_pb_postgresql_proto protoreflect.FileDescriptor
View Source
var PostgresqlOperation_ServiceDesc = grpc.ServiceDesc{
	ServiceName: "postgresql.PostgresqlOperation",
	HandlerType: (*PostgresqlOperationServer)(nil),
	Methods: []grpc.MethodDesc{
		{
			MethodName: "PhysicalBackup",
			Handler:    _PostgresqlOperation_PhysicalBackup_Handler,
		},
		{
			MethodName: "LogicalBackup",
			Handler:    _PostgresqlOperation_LogicalBackup_Handler,
		},
		{
			MethodName: "Restore",
			Handler:    _PostgresqlOperation_Restore_Handler,
		},
	},
	Streams:  []grpc.StreamDesc{},
	Metadata: "pkg/agent/app/postgresql/pb/postgresql.proto",
}

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

Functions

func RegisterPostgresqlOperationServer

func RegisterPostgresqlOperationServer(s grpc.ServiceRegistrar, srv PostgresqlOperationServer)

func RegistryGrpcApp

func RegistryGrpcApp()

Types

type LocalStorage

type LocalStorage struct {
	Path string `protobuf:"bytes,1,opt,name=path,proto3" json:"path,omitempty"`
	// contains filtered or unexported fields
}

func (*LocalStorage) Descriptor deprecated

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

Deprecated: Use LocalStorage.ProtoReflect.Descriptor instead.

func (*LocalStorage) GetPath

func (x *LocalStorage) GetPath() string

func (*LocalStorage) ProtoMessage

func (*LocalStorage) ProtoMessage()

func (*LocalStorage) ProtoReflect

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

func (*LocalStorage) Reset

func (x *LocalStorage) Reset()

func (*LocalStorage) String

func (x *LocalStorage) String() string

type LogicalBackupMode

type LogicalBackupMode int32
const (
	LogicalBackupMode_Full     LogicalBackupMode = 0
	LogicalBackupMode_Database LogicalBackupMode = 1
	LogicalBackupMode_Table    LogicalBackupMode = 2
)

func (LogicalBackupMode) Descriptor

func (LogicalBackupMode) Enum

func (LogicalBackupMode) EnumDescriptor deprecated

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

Deprecated: Use LogicalBackupMode.Descriptor instead.

func (LogicalBackupMode) Number

func (LogicalBackupMode) String

func (x LogicalBackupMode) String() string

func (LogicalBackupMode) Type

type LogicalBackupRequest

type LogicalBackupRequest struct {
	BackupFile        string            `protobuf:"bytes,1,opt,name=backup_file,json=backupFile,proto3" json:"backup_file,omitempty"`
	Username          string            `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
	Password          string            `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"`
	Database          string            `protobuf:"bytes,4,opt,name=database,proto3" json:"database,omitempty"`
	Table             string            `protobuf:"bytes,5,opt,name=table,proto3" json:"table,omitempty"`
	LogicalBackupMode LogicalBackupMode `protobuf:"varint,6,opt,name=logicalBackupMode,proto3,enum=postgresql.LogicalBackupMode" json:"logicalBackupMode,omitempty"`
	// Types that are valid to be assigned to StorageType:
	//
	//	*LogicalBackupRequest_S3Storage
	//	*LogicalBackupRequest_LocalStorage
	StorageType isLogicalBackupRequest_StorageType `protobuf_oneof:"StorageType"`
	// contains filtered or unexported fields
}

func (*LogicalBackupRequest) Descriptor deprecated

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

Deprecated: Use LogicalBackupRequest.ProtoReflect.Descriptor instead.

func (*LogicalBackupRequest) GetBackupFile

func (x *LogicalBackupRequest) GetBackupFile() string

func (*LogicalBackupRequest) GetDatabase

func (x *LogicalBackupRequest) GetDatabase() string

func (*LogicalBackupRequest) GetLocalStorage

func (x *LogicalBackupRequest) GetLocalStorage() *LocalStorage

func (*LogicalBackupRequest) GetLogicalBackupMode

func (x *LogicalBackupRequest) GetLogicalBackupMode() LogicalBackupMode

func (*LogicalBackupRequest) GetPassword

func (x *LogicalBackupRequest) GetPassword() string

func (*LogicalBackupRequest) GetS3Storage

func (x *LogicalBackupRequest) GetS3Storage() *S3Storage

func (*LogicalBackupRequest) GetStorageType

func (x *LogicalBackupRequest) GetStorageType() isLogicalBackupRequest_StorageType

func (*LogicalBackupRequest) GetTable

func (x *LogicalBackupRequest) GetTable() string

func (*LogicalBackupRequest) GetUsername

func (x *LogicalBackupRequest) GetUsername() string

func (*LogicalBackupRequest) ProtoMessage

func (*LogicalBackupRequest) ProtoMessage()

func (*LogicalBackupRequest) ProtoReflect

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

func (*LogicalBackupRequest) Reset

func (x *LogicalBackupRequest) Reset()

func (*LogicalBackupRequest) String

func (x *LogicalBackupRequest) String() string

type LogicalBackupRequest_LocalStorage

type LogicalBackupRequest_LocalStorage struct {
	LocalStorage *LocalStorage `protobuf:"bytes,8,opt,name=local_storage,json=localStorage,proto3,oneof"`
}

type LogicalBackupRequest_S3Storage

type LogicalBackupRequest_S3Storage struct {
	S3Storage *S3Storage `protobuf:"bytes,7,opt,name=s3_storage,json=s3Storage,proto3,oneof"`
}

type PhysicalBackupRequest

type PhysicalBackupRequest struct {
	BackupFile string `protobuf:"bytes,1,opt,name=backup_file,json=backupFile,proto3" json:"backup_file,omitempty"`
	Username   string `protobuf:"bytes,2,opt,name=username,proto3" json:"username,omitempty"`
	Password   string `protobuf:"bytes,3,opt,name=password,proto3" json:"password,omitempty"`
	// Types that are valid to be assigned to StorageType:
	//
	//	*PhysicalBackupRequest_S3Storage
	//	*PhysicalBackupRequest_LocalStorage
	StorageType isPhysicalBackupRequest_StorageType `protobuf_oneof:"StorageType"`
	// contains filtered or unexported fields
}

func (*PhysicalBackupRequest) Descriptor deprecated

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

Deprecated: Use PhysicalBackupRequest.ProtoReflect.Descriptor instead.

func (*PhysicalBackupRequest) GetBackupFile

func (x *PhysicalBackupRequest) GetBackupFile() string

func (*PhysicalBackupRequest) GetLocalStorage

func (x *PhysicalBackupRequest) GetLocalStorage() *LocalStorage

func (*PhysicalBackupRequest) GetPassword

func (x *PhysicalBackupRequest) GetPassword() string

func (*PhysicalBackupRequest) GetS3Storage

func (x *PhysicalBackupRequest) GetS3Storage() *S3Storage

func (*PhysicalBackupRequest) GetStorageType

func (x *PhysicalBackupRequest) GetStorageType() isPhysicalBackupRequest_StorageType

func (*PhysicalBackupRequest) GetUsername

func (x *PhysicalBackupRequest) GetUsername() string

func (*PhysicalBackupRequest) ProtoMessage

func (*PhysicalBackupRequest) ProtoMessage()

func (*PhysicalBackupRequest) ProtoReflect

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

func (*PhysicalBackupRequest) Reset

func (x *PhysicalBackupRequest) Reset()

func (*PhysicalBackupRequest) String

func (x *PhysicalBackupRequest) String() string

type PhysicalBackupRequest_LocalStorage

type PhysicalBackupRequest_LocalStorage struct {
	LocalStorage *LocalStorage `protobuf:"bytes,5,opt,name=local_storage,json=localStorage,proto3,oneof"`
}

type PhysicalBackupRequest_S3Storage

type PhysicalBackupRequest_S3Storage struct {
	S3Storage *S3Storage `protobuf:"bytes,4,opt,name=s3_storage,json=s3Storage,proto3,oneof"`
}

type PostgresqlOperationClient

type PostgresqlOperationClient interface {
	PhysicalBackup(ctx context.Context, in *PhysicalBackupRequest, opts ...grpc.CallOption) (*Response, error)
	LogicalBackup(ctx context.Context, in *LogicalBackupRequest, opts ...grpc.CallOption) (*Response, error)
	Restore(ctx context.Context, in *RestoreRequest, opts ...grpc.CallOption) (*Response, error)
}

PostgresqlOperationClient is the client API for PostgresqlOperation 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.

type PostgresqlOperationServer

type PostgresqlOperationServer interface {
	PhysicalBackup(context.Context, *PhysicalBackupRequest) (*Response, error)
	LogicalBackup(context.Context, *LogicalBackupRequest) (*Response, error)
	Restore(context.Context, *RestoreRequest) (*Response, error)
	// contains filtered or unexported methods
}

PostgresqlOperationServer is the server API for PostgresqlOperation service. All implementations must embed UnimplementedPostgresqlOperationServer for forward compatibility

type Response

type Response struct {
	Message string `protobuf:"bytes,1,opt,name=message,proto3" json:"message,omitempty"`
	// contains filtered or unexported fields
}

func (*Response) Descriptor deprecated

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

Deprecated: Use Response.ProtoReflect.Descriptor instead.

func (*Response) GetMessage

func (x *Response) GetMessage() string

func (*Response) ProtoMessage

func (*Response) ProtoMessage()

func (*Response) ProtoReflect

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

func (*Response) Reset

func (x *Response) Reset()

func (*Response) String

func (x *Response) String() string

type RestoreRequest

type RestoreRequest struct {
	BackupFile string `protobuf:"bytes,1,opt,name=backup_file,json=backupFile,proto3" json:"backup_file,omitempty"`
	// Types that are valid to be assigned to StorageType:
	//
	//	*RestoreRequest_S3Storage
	//	*RestoreRequest_LocalStorage
	StorageType isRestoreRequest_StorageType `protobuf_oneof:"StorageType"`
	// contains filtered or unexported fields
}

func (*RestoreRequest) Descriptor deprecated

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

Deprecated: Use RestoreRequest.ProtoReflect.Descriptor instead.

func (*RestoreRequest) GetBackupFile

func (x *RestoreRequest) GetBackupFile() string

func (*RestoreRequest) GetLocalStorage

func (x *RestoreRequest) GetLocalStorage() *LocalStorage

func (*RestoreRequest) GetS3Storage

func (x *RestoreRequest) GetS3Storage() *S3Storage

func (*RestoreRequest) GetStorageType

func (x *RestoreRequest) GetStorageType() isRestoreRequest_StorageType

func (*RestoreRequest) ProtoMessage

func (*RestoreRequest) ProtoMessage()

func (*RestoreRequest) ProtoReflect

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

func (*RestoreRequest) Reset

func (x *RestoreRequest) Reset()

func (*RestoreRequest) String

func (x *RestoreRequest) String() string

type RestoreRequest_LocalStorage

type RestoreRequest_LocalStorage struct {
	LocalStorage *LocalStorage `protobuf:"bytes,3,opt,name=local_storage,json=localStorage,proto3,oneof"`
}

type RestoreRequest_S3Storage

type RestoreRequest_S3Storage struct {
	S3Storage *S3Storage `protobuf:"bytes,2,opt,name=s3_storage,json=s3Storage,proto3,oneof"`
}

type S3Storage

type S3Storage struct {
	Endpoint  string `protobuf:"bytes,1,opt,name=endpoint,proto3" json:"endpoint,omitempty"`
	Bucket    string `protobuf:"bytes,2,opt,name=bucket,proto3" json:"bucket,omitempty"`
	AccessKey string `protobuf:"bytes,3,opt,name=access_key,json=accessKey,proto3" json:"access_key,omitempty"`
	SecretKey string `protobuf:"bytes,4,opt,name=secret_key,json=secretKey,proto3" json:"secret_key,omitempty"`
	// contains filtered or unexported fields
}

func (*S3Storage) Descriptor deprecated

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

Deprecated: Use S3Storage.ProtoReflect.Descriptor instead.

func (*S3Storage) GetAccessKey

func (x *S3Storage) GetAccessKey() string

func (*S3Storage) GetBucket

func (x *S3Storage) GetBucket() string

func (*S3Storage) GetEndpoint

func (x *S3Storage) GetEndpoint() string

func (*S3Storage) GetSecretKey

func (x *S3Storage) GetSecretKey() string

func (*S3Storage) ProtoMessage

func (*S3Storage) ProtoMessage()

func (*S3Storage) ProtoReflect

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

func (*S3Storage) Reset

func (x *S3Storage) Reset()

func (*S3Storage) String

func (x *S3Storage) String() string

type UnimplementedPostgresqlOperationServer

type UnimplementedPostgresqlOperationServer struct {
}

UnimplementedPostgresqlOperationServer must be embedded to have forward compatible implementations.

func (UnimplementedPostgresqlOperationServer) LogicalBackup

func (UnimplementedPostgresqlOperationServer) PhysicalBackup

func (UnimplementedPostgresqlOperationServer) Restore

type UnsafePostgresqlOperationServer

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

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

Jump to

Keyboard shortcuts

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