Moved history database creation into the database driver so that history could be better managed.