Refactored Session and DBClient