Ask HN: Tools that can notify us when our REST API call fails
14 points| black_blood | 8 years ago
I have just observed that my production REST API calls are failing (timeout or error status codes) even though the server itself is running. I am not sure since when. As I have very limited user base, no one reported the issue.
I am looking for tools that test our REST API calls continuously and report to us if those calls start failing. Also, are there any other solutions such that the above scenario does not happen again?
Edit: I will/can debug what the issue here is. I am looking for specific simple tools/products that can take my GET API request, call it every n minutes, and notify me if the api request fails.
jamesmishra|8 years ago
fiiv|8 years ago
For timeouts, it may be tougher to do. If you use some kind of reverse proxy to spread the load to instances of your API, then this might be a nice place to start investigating your problems, and there is where you're going to want some tooling. If you're using Node.js, it could be possible the code for a specific endpoint does not send a response (maybe only under certain circumstances) - so you will need to debug that particular aspect of it and ensure that a response is sent, otherwise timeouts will happen.
As for actually sending test requests to your API, the difficultly with this method is that if, for example, you're posting a new user and your tool posts once every 5 mins, then you will have 12 garbage users after an hour. Not to mention that you will need to write a test for each error possibility as well, since it could be that a validation error is causing the timeout. So for this it probably makes sense to write a test suite, and include a test for each of the possible scenarios, or paths through your code.
black_blood|8 years ago
Regarding POSTing a new user every 5 mins, I will not test such an API call. I will test a simple GET call which does not need any authentication.
So, I am looking for a simple tool that takes my GET API request, calls it every n minutes, and notifies me if the api request fails.
cdnsteve|8 years ago
dmlittle|8 years ago
[1] https://www.pingdom.com/
[2] https://sentry.io/
creichert|8 years ago
black_blood|8 years ago
@Others: One minor point to note here is that the free account allows only one hour Scheduled Monitoring, not more frequently.
jlengrand|8 years ago
http://servsup.co/
It's fully open source
whatnotests|8 years ago
Avalaxy|8 years ago