Documentation
¶
Overview ¶
rpc defines all the RPC interfaces.
Index ¶
- type BackupService
- type Commit
- type DoViewChangeArgs
- type DoViewChangeResp
- type OpRequest
- type Operation
- type OperationResult
- type PrepareArgs
- type PrepareOk
- type RecoveryRequest
- type RecoveryResponse
- type RecoveryService
- type Request
- type Response
- type StartViewArgs
- type StartViewChangeArgs
- type StartViewChangeResp
- type StartViewResp
- type ViewService
- type VrgoService
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type BackupService ¶
type BackupService interface {
Prepare(args *PrepareArgs, resp *PrepareOk) error
}
type DoViewChangeArgs ¶
type DoViewChangeArgs struct { ViewNum int Log []OpRequest LatestNormalViewNum int OpNum int CommitNum int Id int }
DoViewChangeArgs is the arguments to tell the new primary to start a new view.
type DoViewChangeResp ¶
type DoViewChangeResp struct { }
DoViewChangeResp is the response to a DoViewChange message.
type OpRequest ¶
OpRequest represents an operation record that has a Request and a operation number.
type OperationResult ¶
type OperationResult struct {
Message string
}
OperationResult is the result of the user operation.
type PrepareArgs ¶
Prepare is the input argument type to Echo.
type RecoveryRequest ¶
RecoveryRequest is the request to start a recovery.
type RecoveryResponse ¶
type RecoveryResponse struct { ViewNum int Nonce int Log []OpRequest OpNum int CommitNum int Id int Mode string }
RecoveryRequest is the response to a recovery request.
type RecoveryService ¶
type RecoveryService interface {
Recover(request *RecoveryRequest, response *RecoveryResponse) error
}
RecoveryService is the RPC to perform a recovery.
type Response ¶
type Response struct { ViewNum int RequestNum int OpResult OperationResult Err string }
Response is the output type of RequestRPC.
type StartViewArgs ¶
StartViewArgs is the arguments for the primary to start a new view.
type StartViewChangeArgs ¶
StartViewChangeArgs is the arguments to start a view change.
type StartViewChangeResp ¶
type StartViewChangeResp struct { }
StartViewChangeResp is the response to a StartViewChange message.
type StartViewResp ¶
type StartViewResp struct { }
StartViewResp is the response to a StartView message.
type ViewService ¶
type ViewService interface { // StartViewChange initiates a view change. StartViewChange(*StartViewChangeArgs, *StartViewChangeResp) error // DoViewChange tells the new primary to start a new view. DoViewChange(*DoViewChangeArgs, *DoViewChangeResp) error // StartView tells the backups to transition to a new view. StartView(*StartViewArgs, *StartViewResp) error }
ViewService is the RPC to perform a view change.
type VrgoService ¶
VrgoService defines the APIs Vrgo exposes to users.