> + case 402:
> + exception = new IllegalStateException(message, exception);
> + break;
> + case 404:
> + if
> (!command.getCurrentRequest().getMethod().equals("DELETE")) {
> + exception = new ResourceNotFoundException(message,
> exception);
> + }
> + break;
> + case 405:
> + exception = new IllegalArgumentException(message, exception);
> + break;
> + case 409:
> + exception = new IllegalStateException(message, exception);
> + break;
> + case 500:
> + exception = null;
This doesn't seem to be correct.
Do the 500 errors provide some information in the response? Is there a way you
can determine if you should propagate a `ResourceNotFoundException` or another
more appropriate?
It does not seem right to just blindly ignore any 500 error. We wouldn't know
if it is a *real* server failure or not.
---
Reply to this email directly or view it on GitHub:
https://github.com/jclouds/jclouds-labs/pull/116/files#r22195987