Skip to main content

Scalability (Self-hosted)

The Retool Platform, when run in a self-hosted environment (e.g., AWS, Azure, Google) will rely on compute, storage, networking, and security infrastructure. Many of these services have scalability considerations requiring proper configuration and considerations. The following are some examples.

Best practices

Scale your Retool instance

Resource: https://docs.retool.com/self-hosted/concepts/deploy-at-scale#scale-your-retool-instance
Resource: https://kubernetes.io/docs/tasks/run-application/horizontal-pod-autoscale/
Resource: https://github.com/kubernetes/autoscaler/tree/master/vertical-pod-autoscaler
Resource: https://github.com/kubernetes/autoscaler/tree/master/cluster-autoscaler
Resource: https://karpenter.sh/

Public Cloud providers support the use of auto scaling solutions for both managed nodes and pods. While scaling can be done manually via updates to manifests, use of automation to monitor and scale as necessary should be considered for Production, high-volume environments. The following are mechanisms that should be considered:

  • Horizontal pod auto-scaling (HPA)
  • Vertical pod auto-scaling (VPA)
  • Cluster Autoscaler
  • Karpenter Autoscaler (AWS only)

Employ load balancing

Resource: https://kubernetes.io/docs/concepts/services-networking/ingress/

Load balancing provides a means to distribute traffic across managed nodes and pods within the Kubernetes cluster improving reliability of the application.

Leverage managed database by cloud provider

Resource: https://docs.retool.com/self-hosted/concepts/deploy-at-scale#postgres
Resource: https://aws.amazon.com/rds/features/
Resource: https://azure.microsoft.com/en-us/products/postgresql
Resource: https://cloud.google.com/sql/docs/postgres

The PostgreSQL database container provided with Self-hosted is insufficient for production workloads. Rather the recommendation is to employ a managed PostgreSQL provider such as Amazon Aurora PostgreSQL, Azure Database for PostgreSQL, or Google Cloud SQL. This will provide capabilities such as read-replicas as well as vertical scalability options.