mafintosh/peer-wire-swarm — pull request #7 by Ivshti (2014-04-24 20:35:07+00:00)
Title: Implemented CONNECTION_TIMEOUT

Added a 3 second timeout for each connection. In my experience, almost all (>99%) of successful connections happen within 3 seconds.

This is a huge improvement since before the swarm got stuck on 100 connections despite the fact that most of them were absolutely inactive (no response - connect or handshake). That's until they hit the 25s handshake timeout.