Optimization and Tuning Procedures

Infrastructure and application optimization and tuning after running load tests

Here are some optimization and tuning steps that we usually perform after running load tests:

  • Put all static assets behind a CDN (e.g. AWS CloudFront). Do not overload the Kubernetes pods with serving the static assets
  • Scale Cluster Horizontally - Scale Kubernetes cluster horizontally by adding nodes
  • Scale Cluster Vertically - Scale Kubernetes cluster vertically by using different types of EC2 instances
  • Scale Pods Horizontally - Scale Kubernetes pods horizontally by increasing the replica count
  • Scale Pods Vertically - Scale Kubernetes pods vertically by increasing CPU and Memory limits
  • Scale Nginx Ingress Horizontally - Scale Nginx Ingress pods horizontally by increasing the replica count
  • Scale Nginx Ingress Vertically - Scale Nginx Ingress vertically by increasing CPU and Memory limits
  • Tune Nginx - Tune Nginx parameters (timeouts, worker processes, logs, http)
  • Optimize application and web servers’ parameters (e.g. concurrency, threads and processes, thread pools, timeouts, memory limits)
  • Optimize databases - Optimize database queries and indexes