Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

requestTimeout in 4.x #6331

Closed
ich199 opened this issue Feb 25, 2016 · 4 comments
Closed

requestTimeout in 4.x #6331

ich199 opened this issue Feb 25, 2016 · 4 comments
Labels
bug Fixes for quality problems that affect the customer experience v4.5.0

Comments

@ich199
Copy link

ich199 commented Feb 25, 2016

Hi,

I have been experiencing an issue where Kibana (4.4.1) returns an Unknown Error when running long queries/visualisations. If the Elasticsearch cluster takes longer than 120 seconds to return the results then the error occurs. This seems to be completely unaffected by the elasticsearch.requestTimeout and elasticsearch.shardTimeout settings in the kibana.yml config file. The error appears consistently at 120 seconds.

Initial investigates seem to show that the Kibana server process is closing the connection to the web browser due to a default NodeJS timeout of 120 seconds (https://nodejs.org/docs/v0.12.10/api/http.html#http_server_timeout) as the default value for routes.timeout.socket (http://hapijs.com/api/8.8.1#route-options) is being used in the hapi server connectionOptions in https://github.com/elastic/kibana/blob/4.x/src/server/http/index.js

There also appears to be a second default hapi timeout being hit in the elasticsearch proxy (https://github.com/elastic/kibana/blob/4.x/src/plugins/elasticsearch/lib/create_proxy.js) the if this issue is fixed, of 180 seconds, as described http://hapijs.com/api/8.8.1#built-in-handlers which causes a HTTP 504 Gateway timeout error.

All the changes I have made to remove these default timeouts are in my commmt ich199@86eb9d6

@gmoskovicz gmoskovicz added bug Fixes for quality problems that affect the customer experience v4.4.1 labels Feb 25, 2016
@w33ble w33ble removed the v4.4.1 label Feb 25, 2016
@w33ble
Copy link
Contributor

w33ble commented Feb 25, 2016

@ich199 thanks for the input, and for tracking down the issue.

I see you have all these changes in a local 4.x branch in your repo, but you haven't opened a pull request against that branch, or even that single commit. Would you mind opening a PR?

@ich199
Copy link
Author

ich199 commented Feb 26, 2016

@w33ble Pull request opened as requested.

This was referenced Mar 2, 2016
@w33ble
Copy link
Contributor

w33ble commented Mar 2, 2016

Closed via #6377 and #6385

@jasonswearingen
Copy link

@ich199 thanks for posting this including the complete root cause. I don't use kibana but use hapi and was wondering why my sessions dropped at 120 seconds.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Fixes for quality problems that affect the customer experience v4.5.0
Projects
None yet
Development

No branches or pull requests

5 participants