Lawrence, Rendall
c50a532181
(tested) complete replace logrus with zerolog
...
* remove cobra dependency and split execs to mochi and e2e
* add log init synchronization
2022-05-02 03:13:58 +03:00
Lawrence, Rendall
01064fd21a
(tested) split storage to data and peer interfaces,
...
add option for persisting (or not) torrent approval data
2022-04-16 18:50:19 +03:00
Lawrence, Rendall
8cd8343757
(tested) refactor code
...
* add sentinel master parameter into driver config
* replace yaml double deserialization with `mapstructure` in initializers
* replace struct initializers with registered functions
* add torrent approval MD and a sanitize rest MDs
2022-04-16 00:51:48 +03:00
Lawrence, Rendall
c9e0af8b1e
fix lint errors
2022-04-12 21:48:54 +03:00
Lawrence, Rendall
c1956d68f6
Remove YAML/MD lint configs, reformat stdlib imports
2022-04-12 18:10:51 +03:00
Širhoe Biazhkovič
c7edbb52f2
Merge commits 129aac230aa..828edb8fd8b from https://github.com/chihaya/chihaya
2022-04-12 15:58:14 +03:00
Lawrence, Rendall
4dbbb4ad83
Rename to MoChi
2021-12-21 15:24:25 +03:00
Širhoe Biazhkovič
0a5ac35c4d
Fix e2e execution, append 2to1 hash in approvals, update dependencies
2021-12-21 15:24:25 +03:00
Širhoe Biazhkovič
beb4736b86
Implement simple PGDC methods for storage
...
* sanitize code a little
* move e2e build to 'e2e' tag
2021-12-21 15:24:25 +03:00
Širhoe Biazhkovič
566d99fcd7
Gegin work on shared store for handlers
2021-12-21 15:24:25 +03:00
Širhoe Biazhkovič
8580bb37e0
WIP Add support for custom torrents' approval storages
...
* migrate torrentapproval to list storage
* add initial support for torrent file storage (watch directory with fsnotify)
* replace frontend/http/bencode package with github.com/zeebo/bencode module
* sanitize code (fix warnings)
TODO:
* parse torrent files to get hashes,
* watch directory event types
DON'T use for now
2021-09-04 01:49:01 +03:00
onestraw
e09d11e4b9
fix goimports error
...
Change-Id: I0f6e383ec1081cc47c690fdaab3fd35590a2634b
2018-12-17 16:59:44 +08:00
Jimmy Zelinskie
7dbbc86380
middleware: add a registration model
2017-12-29 16:55:48 -05:00
Leo Balduf
ef166a6159
middleware, config: re-add support for min interval
2017-12-02 22:56:35 +01:00
Jimmy Zelinskie
134744a484
middleware: remove sanitization mw
2017-10-08 18:02:34 -04:00
Leo Balduf
8ed171b0ea
pkg/log: create wrapper around logrus
2017-06-26 20:46:40 +02:00
Cedric Charly
f7becf952b
frontend: TrackerLogic interface returns modified context
...
HandleAnnounce and HandleScrape must return the modified context changed
by the hooks. These contexts are passed to AfterAnnounce and AfterScrape
for further use.
Closes #304
2017-06-07 19:25:12 -05:00
Jimmy Zelinskie
cb55019ab8
*: add structured logging
2017-05-07 04:30:22 -04:00
Jimmy Zelinskie
a4b08c021b
mv pkg/stopper pkg/stop
...
This makes most of the callsites stutter slightly less.
2017-02-02 21:09:25 -05:00
Jimmy Zelinskie
3f29aa358b
middleware: sanitize max scrape infohashes
...
Fixes #268 .
2017-02-02 02:32:35 -05:00
Leo Balduf
102b032c43
udp: fix ordering of scrapes
2017-01-30 13:07:14 +01:00
Leo Balduf
3c098c0703
middleware: add sanitization hook
2017-01-20 20:29:59 +01:00
Jimmy Zelinskie
e3e545e22e
stopper: move to pkg package
...
This also adds a package docs for the stopper package.
2016-12-11 21:36:01 -05:00
Leo Balduf
86ebb108fc
cmd/chihaya: stop hooks
...
Fixes #214 .
2016-09-24 19:51:18 -04:00
Leo Balduf
3ec6f10e93
hooks: add response hook
...
Fixes #216
2016-09-08 16:02:01 -04:00
Leo Balduf
565ac21834
hooks: add swarm interaction
2016-09-08 15:16:25 -04:00
Leo Balduf
1ff41d7882
middleware: make hooks return a context
2016-09-05 18:26:04 -04:00
Leo Balduf
146fbedb86
general: add missing documentation
...
Fixes #46
2016-09-05 14:58:58 -04:00
Jimmy Zelinskie
fa32839623
replace std log w/ logrus
...
There still needs to be much more logged with the debug level.
2016-09-05 12:10:42 -04:00
Jimmy Zelinskie
e39da6b4e6
main: add CreateHooks() method for ConfigFile
...
This change simplifies middleware.Logic to having only one list of
PreHooks and one list of PostHooks.
2016-09-01 19:48:49 -04:00
Jimmy Zelinskie
fc13031d96
move to std context package
2016-08-16 22:34:05 -04:00
Jimmy Zelinskie
cc6614c474
rename back to chihaya
2016-08-16 22:17:10 -04:00
Jimmy Zelinskie
c3137508d0
make new storage pkg with memory impl
2016-08-16 22:17:10 -04:00
Jimmy Zelinskie
c9fe95b103
s/backend/middleware
2016-08-16 22:17:10 -04:00