struct Raft::Log::Metadata

Overview

Persistent metadata that survives restarts: the current term and the candidate this node voted for (if any) in the current term.

Defined in:

raft/log.cr

Constructors

Instance Method Summary

Constructor Detail

def self.new(current_term : UInt64, voted_for : String | Nil) #

[View source]

Instance Method Detail

def clone #

[View source]
def copy_with(current_term _current_term = @current_term, voted_for _voted_for = @voted_for) #

[View source]
def current_term : UInt64 #

def voted_for : String | Nil #