3

I am observing a lot of 5xx errors on my Application load balancer logs. I have a dropwizard application listening to HTTP requests behind the ALB. On reading about ALB, I found AWS documentation says: -

If you use HTTP and HTTPS listeners, we recommend that you enable the HTTP keep-alive option for your instances. You can enable keep-alive in your web server settings or in the kernel settings for your instances. Keep-alive, when enabled, enables the load balancer to reuse connections to your instance, which reduces the CPU utilization. To ensure that the load balancer is responsible for closing the connections to your instance, make sure that the value you set for the HTTP keep-alive time is greater than the idle timeout setting on your load balancer.

My current dropwizard configuration.yml file is

server:
  maxThreads: 100
  maxQueuedRequests: 10
  applicationContextPath: /e2e
  applicationConnectors:
    - type: http
      port: 8080

  adminConnectors:
    - type: http
      port: 8081

My ELB idle timeout is set to 60 seconds. But reading this I found that default dropwizard application timeout is 0ms. How can I configure Keep-alive configuration for my dropwizard application?

Adi
  • 387
  • 3
  • 6
  • 14

0 Answers0