attach() function to use existing connect server