HERE API autosuggest 503 service unavailable - here-api

We have been getting 503 Service Unavailable responses recently using the HERE API autosuggest endpoint. When it occurs, it can last for hours. Below is a typical request we get a 503 response from:
https://places.api.here.com/places/v1/autosuggest?q=Bradford&at=52.8,-1.4&addressFilter=countryCode=GB&result_types=address,place&app_code=########&app_id=###########
We have been using this service for a long while now and majority of the time the endpoint responds as expected. However, we are using it in a production environment, so any downtime (especially hours) is not good. Can we do anything when 503 occurs (E.g. calling a different endpoint)?
Thank you for any help or suggestions

Unfortunately no you cannot, outside of ensuring your application itself responds correctly to the error. You can also bookmark our status page (https://status.here.com/status) for more information when something goes wrong. I'm sorry the API was flakey for you recently, but hopefully this is just a temporary issue and doesn't return.

Related

Apify task suddenly returning 403 and 503 errors after working for months

Not sure why this is occurring. I've been using this daily for months and it suddenly broke this morning. Its returning the following error.
CrawlerError: The page couldn't be opened (status: fail, url: https://history.com/this-day-in-history/, lastResourceError: {"errorCode":403,"errorString":"Error downloading https://history.com/this-day-in-history/ - server replied: Service Unavailable","id":1,"status":503,"statusText":"Service Unavailable","url":"https://history.com/this-day-in-history/"}, lastResourceTimeoutResponse: null)
Nothing in the code has changed, website is still up and running fine. Is there any reason why it might stop working suddenly?
This might mean that the website now recognizes you as a bot and is blocking your requests. I would check some articles in this docs section. We are also working on anti-scraping guide.

Getting Status 504 using Rest Routing API

Since today other people and me are getting 504 Response / Timeout while using the Rest Routing API.
Yesterday everything worked fine. When I try to call the API via Browser I also get 504 Gateway Timeout.
Other APIs are working as expected. It's only the Routing API which fails with 504.
Requests are sent from Germany.
The status page shows that everything is up and running, but the Routing API is unreachable.
It started to work again as it should 3 minutes ago..
So I think the problem was solved by here.com ..

Random 500 errors on IIS

I have been working on an application that provides some web services to a client. The MVC application is built on .Net 4.5 framework. Everything worked fine until we looked at the response statistics our client had generated, where we could see we weren’t responding 100%. The statistics showed response drop to 90%-95% every other day.
Inspecting the logs
The first thing I did was to check our application log where I couldn’t find any exceptions logged. We log all (unhandled) exceptions in our application, which would normally lead to an error HTTP status code, so finding no such exception made me think that the request has not reached the application at all. The next step was to check the IIS access logs and there I could not find any 500 errors. I was under the impression that something is going on with the network which is causing 500's.
Upon further investigation, I realized those are being generated by IIS server. I found this by setting up Failed Request Tracing on IIS and after a while I found following error logged:
ModuleName - ManagedPipelineHandler Notification -
EXECUTE_REQUEST_HANDLER HttpStatus - 500 HttpReason - Error Retrieving
Data HttpSubStatus - 0 ErrorCode -The operation completed
successfully. (0x0)
I've looked at various stackoverflow posts but nothing really helped me. I guess it is because of no of requests we make per minute around 200 requests per minute). But I get response for 90-95% requests.
Attached detailed error log here
I figured out what the error is. .Net servers don't receive these requests in the first place, these are getting lost in the network. There is an oracle gateway which is buggy and killing few requests.

API Status Page Response Codes

(This is sort of an abstract philosophical question. But I believe it has objective concrete answers.)
I'm writing an API, my API has a "status" page (like, https://status.github.com/).
If whatever logic I have in place to determine the status says everything is good my plan would be to return 200 OK, and a JSON response with more information about each service tested by my status page.
But what if my logic says the API is down? Say the database isn't responding or something.
I think I want to return 500 INTERNAL SERVER ERROR (or 503 SERVICE NOT AVAILABLE) along with a JSON response with more details.
However, is that breaking the HTTP Status Code spec? Would that confuse end users? My status page itself is working just fine in that case. So maybe it should return 200? But that would mean anyone using it would have to dig into the body looking for a specific parameter to determine the API's status vs. just checking the HTTP Status Code. (Also if my status page itself was broken, I'm fine with the end user taking that to mean the API is down since that's a pretty bad sign...)
Thoughts? Is there official protocol on how a status page should work?
https://www.w3.org/Protocols/rfc2616/rfc2616-sec10.html
For me the page should return 200 unless has problems itself. Is true that is easier to check the status code of a response than parsing but using HTTP status codes to encode application informations breaks what people (and spiders) expect. If a spider passes for your page and sees a 500 or 503 will think your site has a page with problems, not that that page is ok and is signaling that the site is down.
Also, as you notice, it wont' be possible to distinguish between the service is down and the status page is down cases, with the last the only one that should send 500. Also, what if you show more than one service like the twitter status page ? Use 200.
Related: https://stackoverflow.com/a/943021/1536382 https://stackoverflow.com/a/34324179/1536382

Which HTTP status code should be returned when page is being edited and therefore not available?

Let's say an URL was public, accessible for all, but right now is being edited and, therefore, is temporary unavailable, but it will be available in the near future.
Which HTTP status code should be returned when page is being edited?
As told by #JennyD this is as easy as searching just a bit. On Wikipedia you have the list of HTTP error (or status) codes http://en.wikipedia.org/wiki/List_of_HTTP_status_codes
503 seem to be the one you are looking for:
503 Service Unavailable
The server is currently unavailable (because it is overloaded or down for maintenance). Generally, this is a temporary state.

Resources