pub enum Graph {
Line,
FourRegular,
}
Expand description
The graph type to use for dandelion routing, the dandelion paper recommends Graph::FourRegular
.
The decision between line graphs and 4-regular graphs depend on the priorities of the system, if linkability of transactions is a first order concern then line graphs may be better, however 4-regular graphs can give constant-order privacy benefits against adversaries with knowledge of the graph.
See appendix C of the dandelion++ paper.
Variants§
Line
Line graph.
When this is selected one peer will be chosen from the outbound peers each epoch to route transactions to.
In general this is not recommend over Graph::FourRegular
but may be better for certain systems.
FourRegular
Quasi-4-Regular.
When this is selected two peers will be chosen from the outbound peers each epoch, each stem transaction received will then be sent to one of these two peers. Transactions from the same node will always go to the same peer.
Trait Implementations§
impl Copy for Graph
Auto Trait Implementations§
impl Freeze for Graph
impl RefUnwindSafe for Graph
impl Send for Graph
impl Sync for Graph
impl Unpin for Graph
impl UnwindSafe for Graph
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> WithSubscriber for T
impl<T> WithSubscriber for T
Source§fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
Source§fn with_current_subscriber(self) -> WithDispatch<Self>
fn with_current_subscriber(self) -> WithDispatch<Self>
Layout§
Note: Most layout information is completely unstable and may even differ between compilations. The only exception is types with certain repr(...)
attributes. Please see the Rust Reference's “Type Layout” chapter for details on type layout guarantees.
Size: 1 byte
Size for each variant:
Line
: 0 bytesFourRegular
: 0 bytes