Completed code for 3 different operations which will always throw an exception that the connection was forcibly closed.