Moved MySQL initialization logic to different classes.