Skip to content

DevX: Q2B2 GCP cost savings

Created by: kalanchan

DRAFT - TODO

Problem

Dotcom and preprod were largely over provisioned as at the time multi-tenancy was the prioritized strategy for Sourcegraph. Now that Cloud (Single tenancy) is the new strategy, there is a huge opportunity to tune our infrastructure for cost and performance.

Scope

An GCP spend analysis has been completed, and there is an opportunity to reduce our cluster size by up to 50%. This could translate to $30000/month in savings. Further tuning can be made to each service itself to find a balance between spend and performance.

  • Boundaries
    • Soucegraph dotcom and preprod for now
    • Other workloads and GCP projects can be analyzed in the future for further cost saving opportunities
  • Definition of done
    • Being able to reduce cluster size without impacting SRE and performance
    • Ability to show cost savings from month to month basis
  • How
    • Utilize GCP Cost optimization tool for dotcom and preprod
    • Extract monitored usage from Kubecost (usage current being logged, need ~15 days to get clearer picture)
    • Once targetted CPU/Mem ratio has been identified, make changes to infrastructure and deployments files
    • Follow approach in scratch doc

Tracked issues

Legend

  • 👩 Customer issue
  • 🐛 Bug
  • 🧶 Technical debt
  • 🎩 Quality of life
  • 🛠Roadmap
  • 🕵Spike
  • 🔒 Security issue
  • 🙆 Stretch goal