hoverfly-java
hoverfly-java copied to clipboard
Throw exception when not finding a match during simulate
Hoverfly returns a 503 when it can't find a matching response for a request. The application code will then receive this, and try to handle it. In reality it would make more sense for the library to throw something like a NoMatchFoundException on a 503 which is much clearer feedback.
Which thread would that be on ?
The idea is that when a http client makes a request through the proxy, instead of receiving a "no match found" response an exception would be thrown. It would be the thread in which the http client makes this call.
I'm not sure how this could be implemented yet, as the proxy is external to the JVM.