2023-02-20 15:30:59 +05:30
|
|
|
export enum Tags {
|
|
|
|
|
BOOTSTRAP = "bootstrap",
|
|
|
|
|
PEER_EXCHANGE = "peer-exchange",
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
export interface ConnectionManagerOptions {
|
|
|
|
|
/**
|
|
|
|
|
* Number of attempts before a peer is considered non-dialable
|
|
|
|
|
* This is used to not spam a peer with dial attempts when it is not dialable
|
|
|
|
|
*/
|
|
|
|
|
maxDialAttemptsForPeer: number;
|
|
|
|
|
/**
|
|
|
|
|
* Max number of bootstrap peers allowed to be connected to, initially
|
|
|
|
|
* This is used to increase intention of dialing non-bootstrap peers, found using other discovery mechanisms (like Peer Exchange)
|
|
|
|
|
*/
|
|
|
|
|
maxBootstrapPeersAllowed: number;
|
2023-06-08 17:56:29 +05:30
|
|
|
/**
|
|
|
|
|
* Max number of parallel dials allowed
|
|
|
|
|
*/
|
|
|
|
|
maxParallelDials: number;
|
2023-02-20 15:30:59 +05:30
|
|
|
}
|