Updating DB actions for thread safety