Add commit on success to protect against database deadlock