Skip to content

Commit

Permalink
chore: increase limits
Browse files Browse the repository at this point in the history
  • Loading branch information
mkermani144 committed Jun 29, 2024
1 parent d231c54 commit c3d1e55
Show file tree
Hide file tree
Showing 2 changed files with 20 additions and 3 deletions.
13 changes: 11 additions & 2 deletions packages/rosenet-node/lib/createRoseNetNode.ts
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,12 @@ const createRoseNetNode = async ({
denyDialPeer: isPeerUnauthorized,
}),
},
streamMuxers: [mplex()],
streamMuxers: [
mplex({
maxStreamBufferSize: 100_000_000,
maxUnprocessedMessageQueueSize: 200_000_000,
}),
],
peerDiscovery: [
bootstrap({
list: config.relayMultiaddrs,
Expand Down Expand Up @@ -160,7 +165,11 @@ const createRoseNetNode = async ({
}
});
},
{ runOnTransientConnection: true },
{
runOnTransientConnection: true,
maxInboundStreams: 2000,
maxOutboundStreams: 2000,
},
);
RoseNetNodeContext.logger.debug(
`handler for ${ROSENET_DIRECT_PROTOCOL_V1} protocol set`,
Expand Down
10 changes: 9 additions & 1 deletion packages/rosenet-relay/lib/createRoseNetRelay.ts
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,12 @@ const createRoseNetRelay = async ({
denyInboundRelayedConnection: () => true,
denyDialPeer: isPeerUnauthorized,
},
streamMuxers: [mplex()],
streamMuxers: [
mplex({
maxStreamBufferSize: 100_000_000,
maxUnprocessedMessageQueueSize: 200_000_000,
}),
],
services: {
circuitRelay: circuitRelayServer({
reservations: {
Expand All @@ -72,6 +77,9 @@ const createRoseNetRelay = async ({
defaultDataLimit: 0n,
applyDefaultLimit: false,
},
maxInboundHopStreams: 2000,
maxOutboundHopStreams: 2000,
maxOutboundStopStreams: 2000,
}),
pubsub: gossipsub({
allowPublishToZeroPeers: true,
Expand Down

0 comments on commit c3d1e55

Please sign in to comment.