libp2p
    Preparing search index...

    Options for opening a connection to a remote peer.

    interface OpenConnectionOptions {
        force?: boolean;
        initiator?: boolean;
        onProgress?: (evt: OpenConnectionProgressEvents) => void;
        priority?: number;
        signal?: AbortSignal;
    }

    Hierarchy (View Summary)

    Index

    Properties

    force?: boolean

    When opening a connection to a remote peer, if a connection already exists it will be returned instead of creating a new connection. Pass true here to override that and dial a new connection anyway.

    false
    
    initiator?: boolean

    By default a newly opened outgoing connection operates in initiator mode during negotiation of encryption/muxing protocols using multistream-select.

    In some cases such as when the dialer is trying to achieve TCP Simultaneous Connect using the DCUtR protocol, it may wish to act in responder mode, if so pass false here.

    true
    
    onProgress?: (evt: OpenConnectionProgressEvents) => void
    priority?: number

    Connection requests with a higher priority will be executed before those with a lower priority.

    50
    
    signal?: AbortSignal