]> de.git.xonotic.org Git - xonotic/xonstat.git/commit
Save the match_id as game_meta, and use it to keep games unique.
authorAnt Zucaro <azucaro@gmail.com>
Mon, 5 Dec 2011 17:10:18 +0000 (12:10 -0500)
committerAnt Zucaro <azucaro@gmail.com>
Mon, 5 Dec 2011 17:10:18 +0000 (12:10 -0500)
commitcc9c34d002891a4fdb916f40b41fabb7d4e4a6df
treeb7a79f9ed50df6039b42bde8b225930ae7417397
parent6ae2edfb81bbe0643856eb7de50e8c62164570cf
Save the match_id as game_meta, and use it to keep games unique.

POST requests have a "match ID" parameter being sent as an "I" record
within the header. This should be stored in the games table accordingly.
Furthermore, a unique constraint should be placed on the games table
such that all combinations of server_id and match_id are unique in that
table. This prevents duplicate games from being entered by either manual
means or via xonstat-queue.

This change stores the 'I' record in the games table upon submission and
will raise an HTTP 200 exception class if a duplicate entry is found. It
is set to 200 because this is an OK submission, but a duplicate and thus
should not be resubmitted.
xonstat/views/submission.py