Fix deadlocks when running with mysql.

ViolationStore used to connect to the database before the process is forked and executed in catbox, so connection objects got duplicated. Two process try to use the same connection to update the database and mysql client library does not like it at all.