Documentation ¶
Index ¶
- type MockAgentServer
- func (m *MockAgentServer) AddReplicationEntries(context context.Context, in *idl.AddReplicationEntriesRequest) (*idl.AddReplicationEntriesReply, error)
- func (m *MockAgentServer) ArchiveLogDirectory(context.Context, *idl.ArchiveLogDirectoryRequest) (*idl.ArchiveLogDirectoryReply, error)
- func (m *MockAgentServer) CheckDiskSpace(context.Context, *idl.CheckSegmentDiskSpaceRequest) (*idl.CheckDiskSpaceReply, error)
- func (m *MockAgentServer) CreateBackupDirectory(context.Context, *idl.CreateBackupDirectoryRequest) (*idl.CreateBackupDirectoryReply, error)
- func (m *MockAgentServer) CreateRecoveryConf(context context.Context, in *idl.CreateRecoveryConfRequest) (*idl.CreateRecoveryConfReply, error)
- func (m *MockAgentServer) DeleteBackupDirectory(context.Context, *idl.DeleteBackupDirectoryRequest) (*idl.DeleteBackupDirectoryReply, error)
- func (m *MockAgentServer) DeleteDataDirectories(context.Context, *idl.DeleteDataDirectoriesRequest) (*idl.DeleteDataDirectoriesReply, error)
- func (m *MockAgentServer) DeleteStateDirectory(context.Context, *idl.DeleteStateDirectoryRequest) (*idl.DeleteStateDirectoryReply, error)
- func (m *MockAgentServer) DeleteTablespaceDirectories(context.Context, *idl.DeleteTablespaceRequest) (*idl.DeleteTablespaceReply, error)
- func (m *MockAgentServer) NumberOfCalls() int
- func (m *MockAgentServer) RenameDirectories(context.Context, *idl.RenameDirectoriesRequest) (*idl.RenameDirectoriesReply, error)
- func (m *MockAgentServer) RenameTablespaces(context context.Context, in *idl.RenameTablespacesRequest) (*idl.RenameTablespacesReply, error)
- func (m *MockAgentServer) RestorePrimariesPgControl(ctx context.Context, in *idl.RestorePgControlRequest) (*idl.RestorePgControlReply, error)
- func (m *MockAgentServer) RsyncDataDirectories(context.Context, *idl.RsyncRequest) (*idl.RsyncReply, error)
- func (m *MockAgentServer) RsyncTablespaceDirectories(context.Context, *idl.RsyncRequest) (*idl.RsyncReply, error)
- func (m *MockAgentServer) Stop()
- func (m *MockAgentServer) StopAgent(ctx context.Context, in *idl.StopAgentRequest) (*idl.StopAgentReply, error)
- func (m *MockAgentServer) UpdateConfiguration(context.Context, *idl.UpdateConfigurationRequest) (*idl.UpdateConfigurationReply, error)
- func (m *MockAgentServer) UpgradePrimaries(ctx context.Context, in *idl.UpgradePrimariesRequest) (*idl.UpgradePrimariesReply, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type MockAgentServer ¶
type MockAgentServer struct { UpgradeConvertPrimarySegmentsRequest *idl.UpgradePrimariesRequest DeleteDataDirectoriesRequest *idl.DeleteDataDirectoriesRequest Err chan error // contains filtered or unexported fields }
func NewMockAgentServer ¶
func NewMockAgentServer() (*MockAgentServer, func(ctx context.Context, target string, opts ...grpc.DialOption) (*grpc.ClientConn, error), int)
NewMockAgentServer starts a locally running Agent server and returns a struct that facilitates unit testing. It also returns a hub.Dialer that will redirect any outgoing connections to this mock server, as well as the port that the server is listening on.
XXX Why is the Dialer type that we need for this agent defined in the hub package?
func (*MockAgentServer) AddReplicationEntries ¶
func (m *MockAgentServer) AddReplicationEntries(context context.Context, in *idl.AddReplicationEntriesRequest) (*idl.AddReplicationEntriesReply, error)
func (*MockAgentServer) ArchiveLogDirectory ¶
func (m *MockAgentServer) ArchiveLogDirectory(context.Context, *idl.ArchiveLogDirectoryRequest) (*idl.ArchiveLogDirectoryReply, error)
func (*MockAgentServer) CheckDiskSpace ¶
func (m *MockAgentServer) CheckDiskSpace(context.Context, *idl.CheckSegmentDiskSpaceRequest) (*idl.CheckDiskSpaceReply, error)
func (*MockAgentServer) CreateBackupDirectory ¶
func (m *MockAgentServer) CreateBackupDirectory(context.Context, *idl.CreateBackupDirectoryRequest) (*idl.CreateBackupDirectoryReply, error)
func (*MockAgentServer) CreateRecoveryConf ¶
func (m *MockAgentServer) CreateRecoveryConf(context context.Context, in *idl.CreateRecoveryConfRequest) (*idl.CreateRecoveryConfReply, error)
func (*MockAgentServer) DeleteBackupDirectory ¶
func (m *MockAgentServer) DeleteBackupDirectory(context.Context, *idl.DeleteBackupDirectoryRequest) (*idl.DeleteBackupDirectoryReply, error)
func (*MockAgentServer) DeleteDataDirectories ¶
func (m *MockAgentServer) DeleteDataDirectories(context.Context, *idl.DeleteDataDirectoriesRequest) (*idl.DeleteDataDirectoriesReply, error)
func (*MockAgentServer) DeleteStateDirectory ¶
func (m *MockAgentServer) DeleteStateDirectory(context.Context, *idl.DeleteStateDirectoryRequest) (*idl.DeleteStateDirectoryReply, error)
func (*MockAgentServer) DeleteTablespaceDirectories ¶
func (m *MockAgentServer) DeleteTablespaceDirectories(context.Context, *idl.DeleteTablespaceRequest) (*idl.DeleteTablespaceReply, error)
func (*MockAgentServer) NumberOfCalls ¶
func (m *MockAgentServer) NumberOfCalls() int
func (*MockAgentServer) RenameDirectories ¶
func (m *MockAgentServer) RenameDirectories(context.Context, *idl.RenameDirectoriesRequest) (*idl.RenameDirectoriesReply, error)
func (*MockAgentServer) RenameTablespaces ¶
func (m *MockAgentServer) RenameTablespaces(context context.Context, in *idl.RenameTablespacesRequest) (*idl.RenameTablespacesReply, error)
func (*MockAgentServer) RestorePrimariesPgControl ¶
func (m *MockAgentServer) RestorePrimariesPgControl(ctx context.Context, in *idl.RestorePgControlRequest) (*idl.RestorePgControlReply, error)
func (*MockAgentServer) RsyncDataDirectories ¶
func (m *MockAgentServer) RsyncDataDirectories(context.Context, *idl.RsyncRequest) (*idl.RsyncReply, error)
func (*MockAgentServer) RsyncTablespaceDirectories ¶
func (m *MockAgentServer) RsyncTablespaceDirectories(context.Context, *idl.RsyncRequest) (*idl.RsyncReply, error)
func (*MockAgentServer) Stop ¶
func (m *MockAgentServer) Stop()
func (*MockAgentServer) StopAgent ¶
func (m *MockAgentServer) StopAgent(ctx context.Context, in *idl.StopAgentRequest) (*idl.StopAgentReply, error)
func (*MockAgentServer) UpdateConfiguration ¶
func (m *MockAgentServer) UpdateConfiguration(context.Context, *idl.UpdateConfigurationRequest) (*idl.UpdateConfigurationReply, error)
func (*MockAgentServer) UpgradePrimaries ¶
func (m *MockAgentServer) UpgradePrimaries(ctx context.Context, in *idl.UpgradePrimariesRequest) (*idl.UpgradePrimariesReply, error)
Click to show internal directories.
Click to hide internal directories.