use object destructor to delete connector