[−][src]Trait exonum_supervisor::SupervisorInterface
Supervisor service transactions.
Required methods
fn request_artifact_deploy(
&self,
context: CallContext,
artifact: DeployRequest
) -> Result<(), ExecutionError>
&self,
context: CallContext,
artifact: DeployRequest
) -> Result<(), ExecutionError>
Requests artifact deploy.
This request should be initiated by the validator (and depending on the Supervisor
mode several other actions can be required, e.g. sending the same request by majority
of other validators as well).
After that, the supervisor will try to deploy the artifact, and if this procedure
will be successful it will send confirm_artifact_deploy
transaction.
fn confirm_artifact_deploy(
&self,
context: CallContext,
artifact: DeployConfirmation
) -> Result<(), ExecutionError>
&self,
context: CallContext,
artifact: DeployConfirmation
) -> Result<(), ExecutionError>
Confirmation that the artifact was successfully deployed by the validator.
The artifact is registered in the dispatcher if all validators send this confirmation. This confirmation is sent automatically by the node if the deploy succeeds.
fn propose_config_change(
&self,
context: CallContext,
propose: ConfigPropose
) -> Result<(), ExecutionError>
&self,
context: CallContext,
propose: ConfigPropose
) -> Result<(), ExecutionError>
Propose config change
This request should be sent by one of validators as the proposition to change
current configuration to new one. All another validators are able to vote for this
configuration by sending confirm_config_change
transaction.
The configuration application rules depend on the Supervisor
mode, e.g. confirmations
are not required for the Simple
mode, and for Decentralized
mode (2/3+1) confirmations
are required.
Note: only one proposal at time is possible.
fn confirm_config_change(
&self,
context: CallContext,
vote: ConfigVote
) -> Result<(), ExecutionError>
&self,
context: CallContext,
vote: ConfigVote
) -> Result<(), ExecutionError>
Confirm config change
This confirm should be sent by validators to vote for proposed configuration.
Vote of the author of the propose_config_change
transaction is taken into
account automatically.
The configuration application rules depend on the Supervisor
mode.
Trait Implementations
impl Transaction<dyn SupervisorInterface + 'static> for DeployRequest
[src]
const INTERFACE_NAME: &'static str
[src]
const METHOD_ID: MethodId
[src]
fn into_any_tx(self, instance_id: u32) -> AnyTx
[src]
fn sign(
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
[src]
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
impl Transaction<dyn SupervisorInterface + 'static> for DeployConfirmation
[src]
const INTERFACE_NAME: &'static str
[src]
const METHOD_ID: MethodId
[src]
fn into_any_tx(self, instance_id: u32) -> AnyTx
[src]
fn sign(
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
[src]
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
impl Transaction<dyn SupervisorInterface + 'static> for ConfigPropose
[src]
const INTERFACE_NAME: &'static str
[src]
const METHOD_ID: MethodId
[src]
fn into_any_tx(self, instance_id: u32) -> AnyTx
[src]
fn sign(
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
[src]
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
impl Transaction<dyn SupervisorInterface + 'static> for ConfigVote
[src]
const INTERFACE_NAME: &'static str
[src]
const METHOD_ID: MethodId
[src]
fn into_any_tx(self, instance_id: u32) -> AnyTx
[src]
fn sign(
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
[src]
self,
service_id: u32,
public_key: PublicKey,
secret_key: &SecretKey
) -> Verified<AnyTx>
impl Interface for dyn SupervisorInterface
[src]
const INTERFACE_NAME: &'static str
[src]
fn dispatch(
&self,
ctx: CallContext,
method: MethodId,
payload: &[u8]
) -> Result<(), ExecutionError>
[src]
&self,
ctx: CallContext,
method: MethodId,
payload: &[u8]
) -> Result<(), ExecutionError>
Implementors
impl<Mode> SupervisorInterface for Supervisor<Mode> where
Mode: SupervisorMode,
[src]
Mode: SupervisorMode,
fn propose_config_change(
&self,
context: CallContext,
propose: ConfigPropose
) -> Result<(), ExecutionError>
[src]
&self,
context: CallContext,
propose: ConfigPropose
) -> Result<(), ExecutionError>
fn confirm_config_change(
&self,
context: CallContext,
vote: ConfigVote
) -> Result<(), ExecutionError>
[src]
&self,
context: CallContext,
vote: ConfigVote
) -> Result<(), ExecutionError>
fn request_artifact_deploy(
&self,
context: CallContext,
deploy: DeployRequest
) -> Result<(), ExecutionError>
[src]
&self,
context: CallContext,
deploy: DeployRequest
) -> Result<(), ExecutionError>
fn confirm_artifact_deploy(
&self,
context: CallContext,
confirmation: DeployConfirmation
) -> Result<(), ExecutionError>
[src]
&self,
context: CallContext,
confirmation: DeployConfirmation
) -> Result<(), ExecutionError>