Creating host entry for an IP that already exists results in 404 BAD REQUEST
Creating host entry for an IP that already exists results in 404 BAD REQUEST. We should return a better message so the caller knows what is wrong.
#1 Updated by Paul Kelly almost 10 years ago
- Status changed from New to Assigned
- Assignee set to Paul Kelly
Have you looked at the extras/query.rb example file. This shows how additional error information can be retrieved from the HTTPS response. Of course, the information may be missing if this is a bug.
#3 Updated by Justin Sherrill almost 10 years ago
So this may be more of a foreman issue then, rather than a smart-proxy issue. In foreman (using the smart-proxy branch). If you try to create a host, that uses an IP address that already exists, the only error you'll see is 400 BAD Request (sorry, i mistyped 404 in the original issue).
According to Ohad a 400 is probably the correct response code, maybe foreman just needs to extract the error message.