Commit Graph

1571 Commits

Author SHA1 Message Date
Matt Joiner b81913c860 Add TODO item 2016-10-19 01:38:54 +11:00
Thomas Maurice 16ea912b86 Fix not working import 2016-10-15 11:56:15 +11:00
Matt Joiner d4cbdc5c38 Add download rate limiting
Fixes #121.
2016-10-10 17:29:39 +11:00
Matt Joiner ed0dbba384 Make newConnection a method on Client 2016-10-10 16:55:56 +11:00
Matt Joiner c34234bf34 Split connection.rw into separate Reader and Writer
This will make it easier to write hooks for Read and Write separately.
2016-10-10 16:30:51 +11:00
Matt Joiner 099fb9546e Fix Config.UploadRateLimiter comment 2016-10-10 15:03:02 +11:00
Matt Joiner 836bb344f3 Add really simple upload rate limiting and test 2016-10-10 14:58:29 +11:00
Matt Joiner 76c24e70b5 Improve code comments 2016-10-10 14:57:34 +11:00
Matt Joiner 510c03770b Reorder the fields of struct Client 2016-10-10 00:04:14 +11:00
Matt Joiner 44549e7c34 Update README.md
The build status badge is not helpful due to the aggressive testing and badge caching.
2016-10-06 14:58:50 +11:00
Matt Joiner aefc63b9d3 Default to debug mode in client testing config 2016-10-05 15:57:38 +11:00
Matt Joiner de761fb506 Do chunk pooling at Torrent instead of connection level 2016-10-05 15:57:00 +11:00
Matt Joiner d72d93bba7 Speed up mse.handshake.establishS
Remove possible slice allocation, and avoid reflect.
2016-09-30 12:14:34 +10:00
Matt Joiner 47ef753795 peer_protocol.Decoder.Decode: Avoid allocating another intermediate reader
On my system, BenchmarkConnectionMainReadLoop goes from 596 to 1311 MB/s.
2016-09-25 10:31:43 +10:00
Meng Zhuo 23efae91e2 fix unreadable id when started 2016-09-22 12:03:59 +10:00
Meng Zhuo c4979954e8 fix dht-server cmd won't exit after Ctrl+C 2016-09-22 12:03:53 +10:00
Matt Joiner c593366aab Create missing intermediate directories in test 2016-09-21 21:17:22 +10:00
Matt Joiner 3b5f123645 Fix Client.receiveSkeys
Fixes #114. Loop variables in Go are ****ed.
2016-09-21 21:04:52 +10:00
Matt Joiner 0c9c3d35cf Tidy up TestMultipleTorrentsWithEncryption test 2016-09-21 21:02:18 +10:00
Matt Joiner 7856cc6329 Add some more debug logging 2016-09-21 21:00:18 +10:00
Matt Joiner cbeff0a496 Formatting fixes 2016-09-20 18:39:36 +10:00
Matt Joiner 594053609c Fixes for changes to metainfo.MetaInfo.UnmarshalInfo 2016-09-20 18:39:07 +10:00
Matt Joiner b304baad1b Add error return value to metainfo.MetaInfo.UnmarshalInfo
Too many problems caused by bad info bytes in downstream projects.
2016-09-20 12:32:15 +10:00
Michael Howell 9a4fbb01f0 Add a test case for #114 (#117) 2016-09-17 00:01:15 +10:00
Matt Joiner 9126db177b Add Config.{Force,PreferNo}Encryption 2016-09-16 12:42:41 +10:00
Matt Joiner 69f4c5a7e9 Minor comments and test improvement 2016-09-16 12:13:06 +10:00
Matt Joiner 69ffbe6a48 storage: Move sqlite3 import to appropriate file 2016-09-16 11:19:26 +10:00
Matt Joiner 30da5211dd Comment on metainfo.PieceKey 2016-09-16 11:18:36 +10:00
Matt Joiner c45ffd349d Add note in README about the mobile branch 2016-09-13 14:03:55 +10:00
Matt Joiner 7204503206 cmd/torrent: Fix progress bar for zero-length torrents 2016-09-12 17:47:07 +10:00
Ye Yin d3963eedfd Use sync.pool for decode buffer 2016-09-12 17:32:04 +10:00
Matt Joiner d4e30f84f2 Rename some of the unexported file storage types 2016-09-12 17:26:39 +10:00
Matt Joiner e1c6892eca Test empty files and zero piece length for both file and mmap storage backends 2016-09-12 17:11:32 +10:00
Matt Joiner b5ed171ac5 Create zero-length files in the file storage when the torrent storage is opened
Fixes #111.
2016-09-12 17:01:00 +10:00
Matt Joiner 4d10fd3496 Fix issue #112 2016-09-12 16:54:43 +10:00
Matt Joiner 011838998e Add test for issue #111 and #112 2016-09-12 16:53:20 +10:00
Matt Joiner 39f5d76de4 Add a benchmark for readMainLoop piece decoding 2016-09-11 15:43:57 +10:00
Matt Joiner 2fc814b5eb Move Client.connectionLoop to connection.mainReadLoop 2016-09-11 14:32:56 +10:00
Matt Joiner 5d7882a79d Remove unused trackerTier and shuffleTier 2016-09-11 14:12:03 +10:00
Matt Joiner f47fd8c969 Move TorrentSpec stuff into its own file 2016-09-11 14:09:40 +10:00
Ben Gadbois e34891f42b Comment typo (#110) 2016-09-07 09:43:29 +10:00
Matt Joiner 1100aaa553 Relax the seeder torrent connection stats test
The values have changed due to the recent storage change, I'm not sure why, and I don't know if it's important.
2016-09-02 15:26:21 +10:00
Matt Joiner 1e919dd6b1 Rework storage interfaces to make them simpler to implement
This allows lots of behaviour to be baked into the new Client, Torrent and Piece wrappers, rather than duplicating (badly) them in all the backend implementations.
2016-09-02 15:10:57 +10:00
Matt Joiner db3be3441f storage.boltDB: Some comments, and use global completedValue 2016-08-31 21:00:44 +10:00
Matt Joiner ab8349eee1 Improve test reliability on Linux and reduce log noise in tests 2016-08-31 20:14:57 +10:00
Matt Joiner c121615fab Extract chunkSize as a const 2016-08-31 20:11:04 +10:00
Matt Joiner 1a1676c445 Pass seed option to Config for cmd/torrent (#108) 2016-08-31 19:33:54 +10:00
Ye Yin 2fba33d5a2 Pass seed option to Config for cmd/torrent 2016-08-31 17:20:20 +08:00
Matt Joiner e51cb07f6e Uncomment the error handling in storage.boltDBPiece.ReadAt 2016-08-31 18:02:45 +10:00
Matt Joiner 3c2db92a83 Add boltdb storage backend 2016-08-31 17:48:50 +10:00