Increasing the service-manager Timeouts for Connection and Requests

For systems under heavy load, the timeout values of the service-manager that define how long to wait for a connection keep-alive or request answer were defined too low. Also, the Hystrix mechanism that takes the entire microservice out of business when it seems to be overloaded (i.e., it is not answering within the timeouts) does not help if there is only one instance of the microservice overall. To raise the timeout values to more graceful values and deactivate the Hystrix mechanism, follow these steps:

  1. Stop the service-manager service.
  2. Edit the file <service-manager>\config\application-prod.yml.
  3. Change the values of the following lines to the ones shown below.

    service:
      connection-timeout-ms: 60000
      socket-timeout-ms: 300000

    Important note: The suggested values were determined by best guess and trial and error and should only be seen as a recommendation. It may be necessary to adapt them to your local situation/needs.

  4. Add the following line: 

    feign.hystrix.enabled: false

  5. Restart the service-manager service. The timeouts are now raised.


If you are implementing a custom microservice, make sure that your custom service's application.yml contains the following lines and inherits the prod-profile.

hystrix.command.default.execution.isolation.thread.timeoutInMilliseconds: ${service.socket-timeout-ms:300000}
ribbon.ReadTimeout: ${service.socket-timeout-ms:300000}
ribbon.ConnectTimeout: ${service.connection-timeout-ms:60000}


If services are going down because of timeouts waiting for Elasticsearch to answer, add or modify the following line in the <service-manager>\config\application-es.yml file:

management.health.elasticsearch.response-timeout: 30000