Turn on mysql autocommit.
Though I am using the db in read only mode without autocommit all reads end up reading at the same snapshot as the original.
This commit is contained in:
parent
ea0760508d
commit
9277bab553
@ -38,6 +38,7 @@ class AlarmProcessor(BaseProcessor):
|
||||
self.finished_queue = finished_queue
|
||||
|
||||
self.mysql = MySQLdb.connect(host=mysql_host, user=mysql_user, passwd=mysql_passwd, db=dbname)
|
||||
self.mysql.autocommit(True)
|
||||
|
||||
@staticmethod
|
||||
def _parse_alarm(alarm_data):
|
||||
|
Loading…
Reference in New Issue
Block a user