Commit Graph

26 Commits

Author SHA1 Message Date
Feross Aboukhadijeh
f285c9dd3c client.stop() no longer calls client.destroy()
You must call client.destroy() manually to clean up resources
2015-05-16 23:24:20 -07:00
Feross Aboukhadijeh
03bed33457 add webtorrent (websocket) tracker server
This PR merges webtorrent-tracker into this repo. Keeping the code in
sync between the two repos was becoming burdensome. This change should
not effect performance of the server since the webtorrent tracker is
disabled by default.

To enable the webtorrent tracker (disabled by default), do:

```js
var server = new Server({ ws: true })
```
2015-03-27 16:19:06 +13:00
Feross Aboukhadijeh
6ac9ae6a6e perf: don't dynamically add new properties to peer objects 2015-02-02 15:20:15 -08:00
Feross Aboukhadijeh
82e6792a6b BREAKING CHANGES
Breaking changes:
- 'listening' event no longer emits with `port` param
- `server.port` property removed (instead, use
`server.http.address().port`)

Added features:
- expose http server as `server.http`
- expose udp server as `server.udp`
- client.destroy() - ungracefully leave the swarm
- server: added `filter` option to black/whitelist torrents

Bugfixes:
- client considers udp tracker errors to be warnings
- emit 'start', 'stop', 'update', etc. AFTER response sent
- fix udp error response action and message being `undefined`

Internal:
- remove `portfinder` dep
- add complete test for `filter` functionality
2015-01-29 14:59:08 -08:00
Astro
d79bf92db0 server: ipv6 support 2014-12-13 00:12:47 +01:00
Feross Aboukhadijeh
79068a49cf Use hex info_hash and peer_id throughout 2014-12-12 02:02:11 -08:00
Astro
aea3c44c08 server: expose getSwarm()
drops capability to pass a *hex* infoHash
2014-12-09 23:18:47 +01:00
Astro
28189a0b12 server tests: fix serverType in announceUrl 2014-12-05 02:41:57 +01:00
Astro
f77015c046 server tests: run udp tests with udp 2014-12-04 17:38:03 +01:00
Feross Aboukhadijeh
01286e2ee7 listen() without port picks random port 2014-08-16 19:05:56 -07:00
Feross Aboukhadijeh
5037cb3e32 unify server http + udp test suites 2014-07-11 03:49:45 -07:00
Feross Aboukhadijeh
b4928f001a Server perf: Use binary info_hash strings (fix #29) 2014-07-10 22:05:56 -07:00
Feross Aboukhadijeh
0a51e59bd0 better test error messages 2014-07-10 21:00:02 -07:00
Feross Aboukhadijeh
15a6f3c715 require('bittorrent-tracker') returns Client 2014-06-07 15:15:00 -07:00
Feross Aboukhadijeh
14034c2848 wait for server close before next test 2014-05-23 20:43:45 -07:00
Feross Aboukhadijeh
b3d4acbb46 simplify server tests 2014-05-23 20:35:01 -07:00
Feross Aboukhadijeh
eddef2f197 print out warning messages in tests 2014-05-23 18:03:50 -07:00
Feross Aboukhadijeh
d1aca7c3d4 disable udp tracker for http server test 2014-05-23 18:01:42 -07:00
Feross Aboukhadijeh
67be6227c0 cleanup server test 2014-05-18 18:35:12 -07:00
Aliaksei Sapach
dfd235d387 fixed test plan 2014-05-18 19:41:42 +03:00
Aliaksei Sapach
55120f5c48 added a failing test 2014-05-18 19:15:20 +03:00
Feross Aboukhadijeh
e5e0fa9e27 minor style cleanup 2014-05-11 17:32:57 -07:00
fisch0920
5064a05dde added client and server support for scrape messages in addition to announce messages (tcp and udp) 2014-05-09 02:38:41 -04:00
Feross Aboukhadijeh
dfd5149d6b fix #11 - support torrents with 64-bit file sizes 2014-04-18 23:28:59 -07:00
Feross Aboukhadijeh
60b7f8dd09 add more thorough server tests 2014-04-18 23:00:40 -07:00
Feross Aboukhadijeh
31b82e0a2b add bittorrent tracker server implementation! 2014-03-27 00:17:49 -07:00