ClusterHQ / powerstrip

Powerstrip: A tool for prototyping Docker extensions
https://clusterhq.com/
Apache License 2.0
302 stars 32 forks source link

Proposal: Returning a message to docker client after powerstrip fails #79

Open aanm opened 9 years ago

aanm commented 9 years ago

Powerstrips should return a message to the docker client that made the request informing the request couldn't be completed if one of the adapters fail. I propose that message to be showed would be a string from the adapter that would be present in ModifiedClientRequest.Body

binocarlos commented 9 years ago

Agreed - a message and a 5xx status code should end up at the docker client. I think we should send the message back in the same format that the normal docker server sends its errors.

ModifiedClientRequest.Body is for normal operations - I think if there is an error, a 500 status and a string that is however the docker server formats its errors - JSON or plaintext?

aanm commented 9 years ago

IMHO since the error is returned in a HTTP form, the error message it should be plainttext