Added logging to the rest client.