To me it seems like hanging would be more of a deterrent than failing requests as developers could simply retry a request on a simulated failure.
Some developers could even try to fire multiple requests and use the fastest one, effectively reducing the failure rate to the app.
It an interesting problem to solve. The one that I would like to see a solution on is allowing end users interact directly with a third party service without exposing the API key or requiring the to do any authentication.
When Google phased out their undocumented weather API that a lot of people used[1], leading up to it for a few weeks they just randomly returned 403 to random requests. Good way to confuse developers and motivate them to use a real, supported API.
Another approach to discourage use in production would be to randomly return incorrect or garbled data. It's still easy to use for learning, but would lead to embarrassing errors or omissions if used for something real.
Comments
To me it seems like hanging would be more of a deterrent than failing requests as developers could simply retry a request on a simulated failure.
Some developers could even try to fire multiple requests and use the fastest one, effectively reducing the failure rate to the app.
It an interesting problem to solve. The one that I would like to see a solution on is allowing end users interact directly with a third party service without exposing the API key or requiring the to do any authentication.
When Google phased out their undocumented weather API that a lot of people used[1], leading up to it for a few weeks they just randomly returned 403 to random requests. Good way to confuse developers and motivate them to use a real, supported API.
[1] http://thenextweb.com/google/2012/08/28/did-google-just-quie...
Another approach to discourage use in production would be to randomly return incorrect or garbled data. It's still easy to use for learning, but would lead to embarrassing errors or omissions if used for something real.
Maybe, but that would just result in less trust in quality of the service. Which errors and hangs would do also.
I'd rather see simulated data if it's purely for development purposes. You would have far more control over the conditions you need to test.