pub enum ValidatorKickoutReason {
UnusedSlashed,
NotEnoughBlocks {
expected: u64,
produced: u64,
},
NotEnoughChunks {
expected: u64,
produced: u64,
},
Unstaked,
NotEnoughStake {
stake_u128: String,
threshold_u128: String,
},
DidNotGetASeat,
NotEnoughChunkEndorsements {
expected: u64,
produced: u64,
},
ProtocolVersionTooOld {
network_version: u32,
version: u32,
},
}
Expand description
Reasons for removing a validator from the validator set.
JSON schema
{
"description": "Reasons for removing a validator from the validator set.",
"oneOf": [
{
"description": "Deprecated",
"type": "string",
"enum": [
"_UnusedSlashed"
]
},
{
"description": "Validator didn't produce enough blocks.",
"type": "object",
"required": [
"NotEnoughBlocks"
],
"properties": {
"NotEnoughBlocks": {
"type": "object",
"required": [
"expected",
"produced"
],
"properties": {
"expected": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"produced": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
}
}
}
},
"additionalProperties": false
},
{
"description": "Validator didn't produce enough chunks.",
"type": "object",
"required": [
"NotEnoughChunks"
],
"properties": {
"NotEnoughChunks": {
"type": "object",
"required": [
"expected",
"produced"
],
"properties": {
"expected": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"produced": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
}
}
}
},
"additionalProperties": false
},
{
"description": "Validator unstaked themselves.",
"type": "string",
"enum": [
"Unstaked"
]
},
{
"description": "Validator stake is now below threshold",
"type": "object",
"required": [
"NotEnoughStake"
],
"properties": {
"NotEnoughStake": {
"type": "object",
"required": [
"stake_u128",
"threshold_u128"
],
"properties": {
"stake_u128": {
"type": "string"
},
"threshold_u128": {
"type": "string"
}
}
}
},
"additionalProperties": false
},
{
"description": "Enough stake but is not chosen because of seat limits.",
"type": "string",
"enum": [
"DidNotGetASeat"
]
},
{
"description": "Validator didn't produce enough chunk endorsements.",
"type": "object",
"required": [
"NotEnoughChunkEndorsements"
],
"properties": {
"NotEnoughChunkEndorsements": {
"type": "object",
"required": [
"expected",
"produced"
],
"properties": {
"expected": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
},
"produced": {
"type": "integer",
"format": "uint64",
"minimum": 0.0
}
}
}
},
"additionalProperties": false
},
{
"description": "Validator's last block proposal was for a protocol version older than\nthe network's voted protocol version.",
"type": "object",
"required": [
"ProtocolVersionTooOld"
],
"properties": {
"ProtocolVersionTooOld": {
"type": "object",
"required": [
"network_version",
"version"
],
"properties": {
"network_version": {
"type": "integer",
"format": "uint32",
"minimum": 0.0
},
"version": {
"type": "integer",
"format": "uint32",
"minimum": 0.0
}
}
}
},
"additionalProperties": false
}
]
}
Variants§
UnusedSlashed
Deprecated
NotEnoughBlocks
Validator didn’t produce enough blocks.
NotEnoughChunks
Validator didn’t produce enough chunks.
Unstaked
Validator unstaked themselves.
NotEnoughStake
Validator stake is now below threshold
DidNotGetASeat
Enough stake but is not chosen because of seat limits.
NotEnoughChunkEndorsements
Validator didn’t produce enough chunk endorsements.
ProtocolVersionTooOld
Validator’s last block proposal was for a protocol version older than the network’s voted protocol version.
Trait Implementations§
Source§impl Clone for ValidatorKickoutReason
impl Clone for ValidatorKickoutReason
Source§fn clone(&self) -> ValidatorKickoutReason
fn clone(&self) -> ValidatorKickoutReason
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for ValidatorKickoutReason
impl Debug for ValidatorKickoutReason
Source§impl<'de> Deserialize<'de> for ValidatorKickoutReason
impl<'de> Deserialize<'de> for ValidatorKickoutReason
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl From<&ValidatorKickoutReason> for ValidatorKickoutReason
impl From<&ValidatorKickoutReason> for ValidatorKickoutReason
Source§fn from(value: &ValidatorKickoutReason) -> Self
fn from(value: &ValidatorKickoutReason) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for ValidatorKickoutReason
impl RefUnwindSafe for ValidatorKickoutReason
impl Send for ValidatorKickoutReason
impl Sync for ValidatorKickoutReason
impl Unpin for ValidatorKickoutReason
impl UnwindSafe for ValidatorKickoutReason
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more