Commit graph

547 commits

Author SHA1 Message Date
Jimmy Zelinskie
8587d3e980 godep: refresh vendored dependencies 2015-02-08 02:15:23 -05:00
Justin Li
54593ff5c2 Merge pull request #43 from chihaya/develop
Update to Go 1.4
2015-02-03 09:22:41 -05:00
Jimmy Zelinskie
c4c678e7a9 http: add enough comments to pass go lint
[ci skip]
2015-02-03 02:54:34 -05:00
Justin Li
da1528eeb8 build: Run Go 1.4 on travis 2015-01-29 12:14:01 -05:00
Justin Li
2bec1f323b deps: Update dependencies to Go 1.4 2015-01-29 12:10:37 -05:00
Jimmy Zelinskie
4d1b730631 docs: update CONTRIBUTING.md
This includes more information about style and the PR process.
[skip ci]
2015-01-28 23:37:02 -05:00
Jimmy Zelinskie
9a4f1a5d2d docs: attempt to keep README within 80 chars
[skip ci]
2015-01-28 23:26:03 -05:00
Jimmy Zelinskie
347eb2d256 remove CONTRIBUTORS
We will let GitHub keep track of this. It isn't up to date anyway.
2015-01-28 23:07:24 -05:00
Jimmy Zelinskie
dd2c1e95fc docs: move contributing info into CONTRIBUTING.MD 2015-01-28 23:06:22 -05:00
Jimmy Zelinskie
88df5e2c74 docs: move driver docs into backend/README.md 2015-01-28 22:51:09 -05:00
Justin Li
87c68f1973 2015 2015-01-01 12:02:25 -05:00
Jimmy Zelinskie
051a3ce26d Fix missing dir in clone step of install instructs
[ci skip]
2014-11-09 17:56:56 -05:00
Jimmy Zelinskie
ddd10d9732 Begin refactor to better encapsulate configuration
This also updates the example_config.json which did not previously work.
Config.Config is now composed of embedded structs of other configs that
can later be used to clearly have a separation of concerns.
2014-11-01 20:12:40 -04:00
Jimmy Zelinskie
d754b5b376 Return PeerMap by reference.
In accordance with `go vet`, locks should only be returned by reference.
2014-10-28 12:28:51 -04:00
Jimmy Zelinskie
d46beb0f7d Remove unkeyed composite literals.
This was done to keep in accordance with `go vet`.
2014-10-28 12:26:37 -04:00
Jimmy Zelinskie
bbf85de692 Rewrite README and include new godep instructions.
[ci skip]
2014-10-27 23:20:09 -04:00
Jimmy Zelinskie
ad955d73db Vendor third party dependencies. 2014-10-23 01:02:22 -04:00
Jimmy Zelinskie
25eb6316be TravisCI now uses Godep and IRC notices. 2014-10-22 21:57:06 -04:00
Jimmy Zelinskie
3c3b6cfd21 Vendor dependencies with Godep. Fixes #35. 2014-10-22 18:45:41 -04:00
Cooper Lees
1920b573c0 Merge pull request #34 from sadbox/master
corrected link to example_config.json in README.md
2014-10-02 10:13:48 -07:00
James McGuire
b47dde4043 corrected link to example_config.json in README.md 2014-10-02 10:09:20 -07:00
Jimmy Zelinskie
deb44da5f0 add missing json struct tag 2014-09-29 15:14:46 -04:00
Cooper Lees
7acabfe9f6 Merge pull request #33 from psaab/develop
Fix IPv4 stats
2014-09-29 12:04:18 -07:00
Paul Saab
be2ddb7e4d Fix IPv4 stats
net.ParseIP() will return a v4mapped address which makes len(ip) ==
IPv6len and breaks stats for IPv4 requests.
2014-09-29 11:55:18 -07:00
Justin Li
7b7e7fce6b Use signed ints for current counts 2014-09-25 15:25:02 -04:00
Justin Li
b778b3ea40 go fmt [ci skip] 2014-09-25 15:12:25 -04:00
Cooper Lees
17a6fefc3b Go routine stat 2014-09-25 11:47:50 -07:00
Justin Li
1ae60da852 Merge pull request #32 from psaab/develop
Limit number of concurrent connections
2014-09-25 14:31:57 -04:00
Paul Saab
3f5b6b55b0 Limit number of concurrent connections
Go's net/http library has no limits in place for number of concurrent
requests currently being processed.  This can result in an enormous
number of goroutines being created and the read/write buffer pools
growing unbounded resulting in OOM situations.
2014-09-25 10:58:07 -07:00
Jimmy Zelinskie
ec71e28fdc Merge pull request #31 from psaab/develop
Introduce TorrentSize stat and replace some locks in PeerMap with atomic increments.
2014-09-24 19:33:30 -04:00
Paul Saab
2b8dec07fe Use atomics to track peermap size 2014-09-24 16:24:36 -07:00
Paul Saab
47613d4bbd Track the total size of the of the torrents map 2014-09-24 16:24:14 -07:00
Paul Saab
f74ef67d08 Only decrement torrent map size if hash exists 2014-09-24 16:22:14 -07:00
Justin Li
9fea8195bb Merge pull request #30 from psaab/develop
Reduce contention on the torrent map
2014-09-24 15:42:29 -04:00
Paul Saab
ad9034da6d Reduce contention on the torrent map
We see the torrent map have quite a bit of contention.  Shard the map by
a configurable number of shards to reduce the times we may contend on
the lock.
2014-09-24 10:23:16 -07:00
Jimmy Zelinskie
b910fdabf5 Organize peers by subnet.
This commit restructures PeerMaps to be a map from Subnet to
PeerID to Peer. This reduces the complexity require to gather peers from
the same subnet.
2014-09-23 23:00:50 -04:00
Jimmy Zelinskie
6a96245d90 AppendPeers now uses readlock. 2014-09-15 22:14:27 -04:00
Justin Li
976a983aa7 go fmt [ci skip] 2014-09-03 10:18:26 -04:00
Cooper Lees
67df033c7f Add configurable HTTP read and write timeouts 2014-09-02 22:24:15 -07:00
Jimmy Zelinskie
0f0296be1e Address missing copyright on storage.go [ci skip] 2014-09-03 00:57:11 -04:00
Jimmy Zelinskie
f001489294 Unlock torrent mutex when continuing purge loop. 2014-09-03 00:52:21 -04:00
Jimmy Zelinskie
417d2a3b12 Disable HTTP KeepAlives 2014-08-26 18:03:44 -04:00
Cooper Lees
26de6d2e9c Respect a clients AF Optional Support - config driven 2014-08-21 07:11:35 -07:00
Jimmy Zelinskie
1d9b2bc322 First step towards removing Tracker Driver.
This feature isn't worth maintaining and if anyone needs to scale beyond
memory on a single box, we can evaluate it then.
2014-08-13 17:45:34 -04:00
Jimmy Zelinskie
e3420b4013 Silence net.OpErrors dealing with accept.
This code is borrowed from:
6e11439113/graceful.go (L52-L58)
2014-08-05 15:00:52 -04:00
Jimmy Zelinskie
fc18028796 Fix Purge reporting all peers as Seeders
PeerMaps now are constructed with a boolean value that tells the map
whether they are hosting seeders or leechers.
2014-08-05 06:57:48 -04:00
Jimmy Zelinskie
01fa778ce2 JSON Encoding for PeerMaps 2014-08-04 07:05:13 -04:00
Jimmy Zelinskie
9e45f77efe Create peermap.go, add documentation 2014-08-04 06:37:31 -04:00
Jimmy Zelinskie
3cb286fb40 Introduce thread-safe PeerMap 2014-08-04 06:15:08 -04:00
Justin Li
d610b4ebb0 Address easy golint comments 2014-08-01 16:16:38 -04:00