Struct redgold_schema::structs::VersionInfo
source · pub struct VersionInfo {
pub executable_checksum: String,
pub commit_hash: Option<String>,
pub next_executable_checksum: Option<String>,
pub next_upgrade_time: Option<i64>,
}Expand description
Used to store the version of the executable and the commit hash of the source code used to build it. Security verifications associated with the node software should be done with this message.
Fields§
§executable_checksum: StringThe value associated with the Sha2-256 hash of the executable calculated with shasum locally Should match github release page.
commit_hash: Option<String>This is only really useful in the security scenario where the node is building from source Otherwise, even if filled with a value from git, it’s not really verified
next_executable_checksum: Option<String>Same as prior hash except the intended upgrade hash of a node, not yet used.
next_upgrade_time: Option<i64>Intended time for performing a software update, for coordination of upgrades (not yet used.)
Implementations§
source§impl VersionInfo
impl VersionInfo
sourcepub fn commit_hash(&self) -> &str
pub fn commit_hash(&self) -> &str
Returns the value of commit_hash, or the default value if commit_hash is unset.
sourcepub fn next_executable_checksum(&self) -> &str
pub fn next_executable_checksum(&self) -> &str
Returns the value of next_executable_checksum, or the default value if next_executable_checksum is unset.
sourcepub fn next_upgrade_time(&self) -> i64
pub fn next_upgrade_time(&self) -> i64
Returns the value of next_upgrade_time, or the default value if next_upgrade_time is unset.
Trait Implementations§
source§impl Clone for VersionInfo
impl Clone for VersionInfo
source§fn clone(&self) -> VersionInfo
fn clone(&self) -> VersionInfo
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moresource§impl Debug for VersionInfo
impl Debug for VersionInfo
source§impl Default for VersionInfo
impl Default for VersionInfo
source§impl<'de> Deserialize<'de> for VersionInfo
impl<'de> Deserialize<'de> for VersionInfo
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>,
source§impl Hash for VersionInfo
impl Hash for VersionInfo
source§impl Message for VersionInfo
impl Message for VersionInfo
source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
source§fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8>where Self: Sized,
source§fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where
B: BufMut,
Self: Sized,
fn encode_length_delimited<B>(&self, buf: &mut B) -> Result<(), EncodeError>where B: BufMut, Self: Sized,
source§fn encode_length_delimited_to_vec(&self) -> Vec<u8>where
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8>where Self: Sized,
source§fn decode<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where
B: Buf,
Self: Default,
fn decode_length_delimited<B>(buf: B) -> Result<Self, DecodeError>where B: Buf, Self: Default,
source§fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self. Read moresource§fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where
B: Buf,
Self: Sized,
fn merge_length_delimited<B>(&mut self, buf: B) -> Result<(), DecodeError>where B: Buf, Self: Sized,
self.source§impl PartialEq for VersionInfo
impl PartialEq for VersionInfo
source§fn eq(&self, other: &VersionInfo) -> bool
fn eq(&self, other: &VersionInfo) -> bool
self and other values to be equal, and is used
by ==.