add callback setter to be called when connection is established