@Override
 public void handleError(ClientHttpResponse response) throws IOException {
   HttpStatus statusCode = getHttpStatusCode(response);
   if (statusCode == HttpStatus.UNAUTHORIZED) {
     loginController.start(this);
   } else {
     super.handleError(response);
   }
 }
 @Override
 public void afterLogin() {
   loginController.finish();
 }