message: optimize p2p
diff: @@ -19,9 +19,9 @@ const createP2PNode = (options) => {
  const defaultListen = [
  //'/ip4/0.0.0.0/tcp/4002',
  '/dns4/webrtc-star-1.swaponline.io/tcp/443/wss/p2p-webrtc-star/',
  - //'/dns4/webrtc-star.discovery.libp2p.io/tcp/443/wss/p2p-webrtc-star',
  - //'/dns4/secure-beyond-12878.herokuapp.com/tcp/443/wss/p2p-webrtc-star/',
  - //'/dns4/wrtc-star2.sjc.dwebops.pub/tcp/443/wss/p2p-webrtc-star/'
  + '/dns4/webrtc-star.discovery.libp2p.io/tcp/443/wss/p2p-webrtc-star',
  + '/dns4/secure-beyond-12878.herokuapp.com/tcp/443/wss/p2p-webrtc-star/',
  + '/dns4/wrtc-star2.sjc.dwebops.pub/tcp/443/wss/p2p-webrtc-star/'
  ]
  const defaultDiscoveryPeers = [
  @@ -82,7 +82,7 @@ const createP2PNode = (options) => {
  dialer: {
  maxParallelDials: 100,
  maxDialsPerPeer: 100,
  - dialTimeout: 30e3
  + dialTimeout: 1e3
  },
  connectionManager: {
  maxConnections: Infinity,
  @@ -109,30 +109,10 @@ const createP2PNode = (options) => {
  },
  bootstrap: {
  enabled: true,
  - interval: 10e3,
  + interval: 1e3,
  list: discoveryPeers || defaultDiscoveryPeers,
  }
  },
  - /*
  - dialer: {
  - maxParallelDials: 100,
  - maxDialsPerPeer: 100,
  - dialTimeout: 30e3
  - },
  - */
  - /*
  - connectionManager: {
  - maxConnections: Infinity,
  - minConnections: 0,
  - pollInterval: 500,
  - defaultPeerValue: 1,
  - maxData: Infinity,
  - maxSentData: Infinity,
  - maxReceivedData: Infinity,
  - maxEventLoopDelay: Infinity,
  - movingAverageInterval: 1000
  - },
  - */
  // @ts-ignore
  relay: {
  enabled: true,
  @@ -144,7 +124,7 @@ const createP2PNode = (options) => {
  dht: {
  enabled: true,
  randomWalk: {
  - enabled: true,
  + enabled: false,
  }
  }
  }
  