A lot of renaming to make DB functionality clearer.