summaryrefslogtreecommitdiff
path: root/lib/Multi
AgeCommit message (Collapse)AuthorFilesLines
2015-07-21Multi::API: Support IPv6Yorhel1-1/+5
This was more trivial than I had expected. I already took ipv6 into account when rewriting the API for AnyEvent (including the use of norm_ip()), so that part was fine. The only part I had to fix was the listening socket, and I had to ensure that the $c->{ip} was correct. The first was easy, and the latter was properly handled by AnyEvent automatically. Looks like AnyEvent automatically 'unpacks' IPv4-mapped IPv6 addresses, so I didn't have to deal with that myself.
2015-07-20Multi::API: Throttle "throttled" error repliesYorhel1-3/+13
This is to save system resources when a misbehaving client keeps sending commands while it's being throttled. It also protects against trivial DoS attacks.
2015-07-18Multi::Maintenance: Fix bug in calculating timer for monthly cronYorhel1-1/+1
AE::timer accepts a time interval as argument, not a complete timestamp. So the monthly cron job hasn't run in a while...
2015-06-21Multi::IRC: Increase delay between random quotesYorhel1-1/+1
2015-06-15Multi::IRC: Some fixes wrt. chat loggingYorhel1-8/+6
2015-05-13Add staff statistic to main menuYorhel1-0/+1
2015-05-11Multi::{Core,Anime}: More fixes regarding UTF-8Yorhel2-11/+14
2015-04-29Multi::(API:IRC): Fix some unicode handling issuesYorhel2-6/+8
I forgot that AnyEvent::Handle works with bytes rather than unicode strings, even though that is kind of obvious. I expected that AnyEvent::IRC would automatically handle the conversion between byte strings and Unicode strings, but it doesn't, so that has to be done manually.
2015-04-27Multi::IRC: Properly handle connection issuesYorhel1-5/+28
2015-04-27Multi::Core: Make log level configurableYorhel1-1/+1
I probably don't want to have the 'trace' log level on the actual server.
2015-04-27Multi::API: Fixed various bugs found while testingYorhel1-4/+7
Ugh I wish I had proper unit tests. Ugh writing proper unit tests is a loooot more work than just doing a bunch of quick manual tests.
2015-04-27Multi::API: Fix bug when querying stuff while logged inYorhel1-1/+1
2015-04-27Multi::API: Fully implement the 'set' command with AnyEventYorhel1-58/+59
2015-04-27Multi::API: Fully implement 'get' command with AnyEventYorhel2-510/+317
2015-04-27Multi: Backport staff database changes from master branchYorhel2-7/+14
Includes changes from 5926ce95395976456c0e15895d13491a81819087 and e20b19ce400ccf382a969a51777e0678ff8d44db
2014-12-21Multi: WIP Converting Multi::API to AnyEventYorhel2-669/+636
2014-10-31Multi::IRC: Converted to use AnyEventYorhel2-525/+379
It's not as fully featured as the previous implementation, but most of those features haven't been used for the past few years anyway. Also added a generic throttle implementation in Multi::Core, which can be re-used for the API.
2014-10-29Multi: Use AnyEvent::Pg's last_query_start_time()Yorhel1-1/+2
The solution that has been implemented upstream is a little different from my patch, but it works well.
2014-10-28Multi: More convenient error handling for one-shot queriesYorhel2-10/+20
2014-10-24Multi::Anime: Converted to use AnyEventYorhel1-172/+176
2014-10-22Multi::RG: Converted to use AnyEventYorhel2-196/+190
AnyEvent::Util::run_cmd() is a godsent. POE was such a hassle in that area.
2014-10-22Multi::APIDump: Converted to use AnyEventYorhel1-94/+61
2014-10-22Multi::Maintenance: Converted to use AnyEventYorhel3-212/+152
2014-10-22Multi: Add pg_cmd function for more robust error handlingYorhel2-20/+49
2014-10-22Multi::Feed: Log SQL timesYorhel1-5/+4
Requires a patch to AnyEvent::Pg: https://rt.cpan.org/Ticket/Display.html?id=99719
2014-10-21Multi: Implement clean shutdown againYorhel2-9/+30
That is, stop all watchers that we want to stop and only shut down when there are no active watchers anymore. This ensures that we're not shutting down in the middle of some operation.
2014-10-21Multi: Rewrote Feed to AnyEvent + various fixesYorhel2-94/+111
2014-10-21Multi: Started on a rewrite to AnyEventYorhel1-74/+57
Currently only Multi::Core works, trying to use any other modules will fail.
2014-10-15Multi::API: Fix login with the new password format changesYorhel1-5/+19
2014-10-15Multi::API: Fix crash on failed loginYorhel1-2/+2
I broke this when changing the column type of login_throttle.timeout.
2014-10-13SQL: Use enum to represent platformsYorhel1-6/+7
I believe I didn't do this conversion earlier (back when I converted the language types) because PostgreSQL didn't support dynamically adding new values to an existing enum back then, and modifying an enum was a huge pain. Recent versions do support this, so there's no reason to keep it as a string. ...I just felt like adding some churn to the code base.
2014-10-11SQL: Convert login_throttle.timeout to a timestamptzYorhel1-2/+2
Easier to work with in custom queries.
2014-09-25Multi: Update maintenance timings + disable usercacheYorhel1-10/+14
The usercache maintenance cron is causing significant downtime each month, so I've disabled it for now.
2014-08-29API: Make sure to honor the new login throttleYorhel1-7/+29
2014-08-29Throttle failed login attempts (10/day)Yorhel1-2/+9
2014-08-21API dump: Add daily votes dumpYorhel1-1/+34
2014-08-21API: Increase max result counts for userlistsYorhel1-2/+4
2014-08-19Multi: Run maintenance tasks at 12:00 GMTYorhel1-7/+4
In particular, don't run the tasks when I'm asleep. The SQL queries that are run during maintenance can deadlock and cause multi to crash. I want to be awake when that happens.
2014-08-19API: Allow access to other users' public listsYorhel1-7/+19
2014-08-16API: Add 'vn' filter to get characterYorhel1-1/+3
2014-07-18API: Add firstchar filter to get vnYorhel1-0/+3
2014-05-16API: Added 'dbstats' commandYorhel1-4/+29
2014-03-11Multi::API: Fix two 'Use of uninitialized value in multiplication'Yorhel1-2/+2
Shouldn't affect behaviour in any way, just get rid of the warnings.
2014-03-10Multi::API: Expose popularity, rating and votecountYorhel1-1/+7
http://vndb.org/t5121
2013-01-18Multi::API: Added basic 'get character' commandYorhel1-4/+96
2013-01-18Added daily-generated JSON dump of the trait informationYorhel1-12/+50
2013-01-05Don't use Multi for processing screenshotsYorhel1-92/+0
TODO: Get rid of the 'processing' flag and all the async loading of screenshot data in the screenshot uploader.
2013-01-05Don't use Multi for processing character imagesYorhel1-36/+2
2013-01-05Don't use Multi for processing VN cover imagesYorhel1-37/+3
I used to do this to avoid loading Image::Magick in each TUWF process, decreasing memory usage, and lowering the blocking time by avoiding too much processing. Memory isn't much of a problem nowadays, and processing images is fast enough, too, so this complexity isn't necessary anymore. (Character images and screenshots pending)
2013-01-05Move api/tags.json.gz to the main domainYorhel1-1/+1
I forgot that the static domain is only intended for files that are never modified. Or at least, not without a URL change. The tags.json.gz doesn't fit into that.