Jimmy Zelinskie
9add47ed07
pull API server out of http
...
Fixes #87 .
2015-10-11 19:23:30 -04:00
Jimmy Zelinskie
0741df3575
logging: add error to udp logs
...
This also makes the format of UDP and HTTP logs a little more similar.
2015-06-26 21:07:29 -04:00
Justin Li
de18172952
Update graceful import path
2015-04-28 20:32:19 -04:00
Justin Li
ae62188711
Disable graceful signal handling
2015-04-28 20:27:39 -04:00
Justin Li
669128c83a
tracker: Pass listen address into tracker.Server.Serve()
2015-02-21 13:16:21 -05:00
Justin Li
afb22c3df6
udp: Add basic logging and more comments
2015-02-20 14:08:46 -05:00
Justin Li
92f3c62456
tracker: Add common interface to start and stop servers
2015-02-20 13:39:19 -05:00
Justin Li
778b64defa
udp: Add UDP configuration, move tracker shutdown to the main package
2015-02-19 23:46:28 -05:00
Jimmy Zelinskie
443fb4b70d
http: add GET route for clients
2015-02-08 02:20:48 -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
87c68f1973
2015 ✨
2015-01-01 12:02:25 -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
Justin Li
b778b3ea40
go fmt [ci skip]
2014-09-25 15:12:25 -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
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
417d2a3b12
Disable HTTP KeepAlives
2014-08-26 18:03:44 -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
ffb3c57181
move whitelist into cfg
2014-07-25 16:58:26 -04:00
Justin Li
cde8251bd3
Add logging for startup failure
2014-07-25 03:43:06 -04:00
Justin Li
3b84fb3f98
Better logging
2014-07-25 03:39:02 -04:00
Justin Li
bacf4f0fd4
Add really really verbose log level
2014-07-23 02:25:15 -04:00
Justin Li
856568f1a8
Always log errors
2014-07-23 01:31:22 -04:00
Justin Li
84195deb58
Correctly handle ErrBadRequest in the announce handler
2014-07-23 01:26:47 -04:00
Jimmy Zelinskie
f8d12054c5
log request failures
2014-07-23 01:20:48 -04:00
Justin Li
6c7abdfa2d
Don't return an HTTP error for "bad request" tracker errors
2014-07-23 00:33:00 -04:00
Justin Li
7fce8c9ad4
Add response time stats
2014-07-22 14:57:36 -04:00
Justin Li
38d2c91ff1
Implement RequestsHandled and RequestsErrored stats
2014-07-22 01:40:52 -04:00
Justin Li
6fdb68d9b2
Implement OpenConnections and ConnectionsAccepted stats
2014-07-22 01:38:07 -04:00
Jimmy Zelinskie
4514705363
re-add /check as per discussion
2014-07-22 01:19:09 -04:00
Jimmy Zelinskie
e78dc74990
added Close to tracker
2014-07-21 03:54:22 -04:00
Justin Li
3ad3f11b2c
Put the query package into http, since it is for http only
2014-07-17 01:00:26 -04:00
Justin Li
da19ed3e21
Separate tracker logic from the http package, step 1
2014-07-17 00:09:56 -04:00
Justin Li
a2e14f79c2
Add peer purging test, and ensure the purging routine runs whenever a tracker is created
2014-07-16 20:08:03 -04:00
Justin Li
cd6204f13d
Purge peers that have not announced for twice the announce interval
2014-07-16 19:38:51 -04:00
Justin Li
7fe6dc3b4e
Simpler, more efficient way of deleting inactive torrents
2014-07-16 15:03:33 -04:00
Justin Li
ea72e9e10c
Initial torrent inactivity purging
2014-07-16 13:24:44 -04:00
Justin Li
f3f58c024c
Use glog levelled logging to decrease announce overhead
2014-07-16 11:52:59 -04:00
Justin Li
d39a40c4fe
Clearer field names for the Tracker struct
2014-07-16 11:29:40 -04:00
Jimmy Zelinskie
ab3d49da9d
pedantic breakline!
2014-07-16 06:01:09 -04:00
Jimmy Zelinskie
23edba6dc6
check route added
2014-07-16 05:44:26 -04:00
Jimmy Zelinskie
65bd11f636
s/setupRoutes/NewRouter
2014-07-16 04:40:51 -04:00
Jimmy Zelinskie
a614f42a94
docs for http package
2014-07-16 04:40:17 -04:00
Jimmy Zelinskie
8ddbf32002
rm last printf in http
2014-07-12 01:52:27 -04:00
Jimmy Zelinskie
e2af935b83
disambiguate routing
2014-07-09 01:34:34 -04:00
Jimmy Zelinskie
afb2376286
api routes; status codes fixed
2014-07-09 00:53:57 -04:00
Justin Li
e08f745f6c
Happy uber-belated new year! ✨
2014-07-06 17:56:54 -04:00
Jimmy Zelinskie
6d5290d85e
transition to httprouter
2014-07-01 21:40:29 -04:00