Skip to content

Commit

Permalink
fix(core-p2p): disable permessage-deflate (#3518)
Browse files Browse the repository at this point in the history
  • Loading branch information
alessiodf authored Feb 20, 2020
1 parent 4aa2ad6 commit 7bbd962
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion packages/core-p2p/src/peer-connector.ts
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ export class PeerConnector implements P2P.IPeerConnector {
port: peer.port,
hostname: peer.ip,
ackTimeout: Math.max(app.resolveOptions("p2p").getBlocksTimeout, app.resolveOptions("p2p").verifyTimeout),
perMessageDeflate: true,
perMessageDeflate: false,
codecEngine: codec,
});

Expand Down
2 changes: 1 addition & 1 deletion packages/core-p2p/src/socket-server/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ export const startSocketServer = async (service: P2P.IPeerService, config: Recor
// See https://github.com/SocketCluster/socketcluster/issues/506 about
// details on how pingTimeout works.
pingTimeout: Math.max(app.resolveOptions("p2p").getBlocksTimeout, app.resolveOptions("p2p").verifyTimeout),
perMessageDeflate: true,
perMessageDeflate: false,
maxPayload: blockMaxPayload + 10 * 1024, // 10KB margin vs block maxPayload to allow few additional chars for p2p message
},
...config.server,
Expand Down

0 comments on commit 7bbd962

Please sign in to comment.