[−][src]Struct ipfs::IpfsOptions
Ipfs node options used to configure the node to be created with UninitializedIpfs
.
Fields
ipfs_path: PathBuf
The path of the ipfs repo (blockstore and datastore).
This is always required but can be any path with in-memory backends. The filesystem backend creates a directory structure alike but not compatible to other ipfs implementations.
Incompatiblity and interop warning
It is not recommended to set this to IPFS_PATH without first at least backing up your existing repository.
keypair: Keypair
The keypair used with libp2p, the identity of the node.
bootstrap: Vec<(Multiaddr, PeerId)>
Nodes used as bootstrap peers.
mdns: bool
Enables mdns for peer discovery and announcement when true.
kad_protocol: Option<String>
Custom Kademlia protocol name. When set to None
, the global DHT name is used instead of
the LAN dht name.
The name given here is passed to libp2p_kad::KademliaConfig::set_protocol_name
.
listening_addrs: Vec<Multiaddr>
Bound listening addresses; by default the node will not listen on any address.
span: Option<Span>
The span for tracing purposes, None
value is converted to tracing::trace_span!("ipfs")
.
All futures returned by Ipfs
, background task actions and swarm actions are instrumented
with this span or spans referring to this as their parent. Setting this other than None
default is useful when running multiple nodes.
Implementations
impl IpfsOptions
[src]
pub fn inmemory_with_generated_keys() -> Self
[src]
Creates an in-memory store backed configuration useful for any testing purposes.
Also used from examples.
Trait Implementations
impl Clone for IpfsOptions
[src]
fn clone(&self) -> IpfsOptions
[src]
fn clone_from(&mut self, source: &Self)
1.0.0[src]
impl Debug for IpfsOptions
[src]
impl<'_> From<&'_ IpfsOptions> for SwarmOptions
[src]
fn from(options: &IpfsOptions) -> Self
[src]
impl<'_> From<&'_ IpfsOptions> for RepoOptions
[src]
fn from(options: &IpfsOptions) -> Self
[src]
Auto Trait Implementations
impl !RefUnwindSafe for IpfsOptions
impl Send for IpfsOptions
impl Sync for IpfsOptions
impl Unpin for IpfsOptions
impl !UnwindSafe for IpfsOptions
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized,
[src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized,
[src]
T: ?Sized,
impl<T> BorrowMut<T> for T where
T: ?Sized,
[src]
T: ?Sized,
fn borrow_mut(&mut self) -> &mut T
[src]
impl<T> From<T> for T
[src]
impl<T> Instrument for T
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T> Instrument for T
[src]
fn instrument(self, span: Span) -> Instrumented<Self>
[src]
fn in_current_span(self) -> Instrumented<Self>
[src]
impl<T, U> Into<U> for T where
U: From<T>,
[src]
U: From<T>,
impl<T> Same<T> for T
type Output = T
Should always be Self
impl<T> ToOwned for T where
T: Clone,
[src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
fn to_owned(&self) -> T
[src]
fn clone_into(&self, target: &mut T)
[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>,
[src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>
[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>,
[src]
U: TryFrom<T>,
type Error = <U as TryFrom<T>>::Error
The type returned in the event of a conversion error.
fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>
[src]
impl<V, T> VZip<V> for T where
V: MultiLane<T>,
V: MultiLane<T>,
fn vzip(self) -> V
impl<T> WithSubscriber for T
[src]
fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self> where
S: Into<Dispatch>,
[src]
S: Into<Dispatch>,