File tree 2 files changed +4
-8
lines changed
2 files changed +4
-8
lines changed Original file line number Diff line number Diff line change @@ -13,7 +13,7 @@ import { gossipsub } from '@chainsafe/libp2p-gossipsub'
13
13
import { webSockets } from '@libp2p/websockets'
14
14
import { webTransport } from '@libp2p/webtransport'
15
15
import { webRTC , webRTCDirect } from '@libp2p/webrtc'
16
- import { CHAT_TOPIC , CIRCUIT_RELAY_CODE } from './constants'
16
+ import { BOOTSTRAP_NODE , CHAT_TOPIC , CIRCUIT_RELAY_CODE } from './constants'
17
17
import * as filters from "@libp2p/websockets/filters"
18
18
19
19
// @ts -ignore
@@ -45,18 +45,14 @@ export async function startLibp2p() {
45
45
} ) , ] ,
46
46
connectionEncryption : [ noise ( ) ] ,
47
47
connectionManager : {
48
- maxConnections : 10 ,
48
+ maxConnections : 100 ,
49
49
minConnections : 1 ,
50
50
} ,
51
51
streamMuxers : [ yamux ( ) ] ,
52
52
peerDiscovery : [
53
53
bootstrap ( {
54
- // #TODO: change to remote address
55
- // list: [
56
- // '/ip4/18.195.246.16/udp/9090/webrtc-direct/certhash/uEiBy_U1UNQ0IDvot_PKlQM_QeU3yx-zCAVaMxxVm2JxWBg/p2p/12D3KooWGTDZj1zAjMCJ8XXx9Z88zAAd6vn3krQYLwZ67S4vMUxz',
57
- // ],
58
54
list : [
59
- '/ip4/127.0.0.1/udp/9090/webrtc-direct/certhash/uEiA2twAWww-g6fXsJe6JPlROwCHbRj6fNgr_WHxiQGEK3g/p2p/12D3KooWLTB1SrjyF8R5Z1MKErcV8abs26eo4LpadQKWsxMUcDBJ'
55
+ BOOTSTRAP_NODE ,
60
56
] ,
61
57
} ) ,
62
58
] ,
Original file line number Diff line number Diff line change @@ -102,7 +102,7 @@ export default function Home() {
102
102
< >
103
103
< h3 className = "text-xl" >
104
104
{ ' ' }
105
- Connected peers ({ peerStats . peerIds . length } ) 👇
105
+ Connected peers ({ getUniqueConnections ( peerStats . connections ) . length } ) 👇
106
106
</ h3 >
107
107
< pre className = "px-2" >
108
108
{ getUniqueConnections ( peerStats . connections )
You can’t perform that action at this time.
0 commit comments