edit connection

edit connection open close functions