big refactoring Connector class 2