Skip to content

Comments

feat: Horizontal scaling support to the Feast operator#6000

Open
ntkathole wants to merge 1 commit intofeast-dev:masterfrom
ntkathole:operator_hpa
Open

feat: Horizontal scaling support to the Feast operator#6000
ntkathole wants to merge 1 commit intofeast-dev:masterfrom
ntkathole:operator_hpa

Conversation

@ntkathole
Copy link
Member

@ntkathole ntkathole commented Feb 21, 2026

What this PR does / why we need it:

  • Add a scaling field to the FeatureStore CRD that supports static replica counts and HPA-based autoscaling for the Feast deployment
  • Validate that file-based persistence (SQLite, DuckDB, registry.db) is rejected when horizontal scaling is configured, since these backends don't support concurrent access
  • Automatically switch deployment strategy from Recreate to RollingUpdate when scaling is enabled to ensure zero-downtime scaling events

CRD & API

  • Added ScalingConfig (with replicas and autoscaling fields) to FeatureStoreServices
  • Added AutoscalingConfig with minReplicas, maxReplicas, metrics, and behavior (maps to HPA v2 spec)
  • Added ScalingStatus to FeatureStoreStatus reporting currentReplicas and desiredReplicas
  • CEL validation rule enforces mutual exclusivity of replicas and autoscaling

Controller

  • New scaling.go with validation, HPA lifecycle management (create/update/delete), replica calculation, and status updates
  • Helper functions isScalingEnabled() and isFilePersistence() in util.go
  • RBAC for horizontalpodautoscalers (get, list, watch, create, update, delete)
  • Controller watches owned HPA resources via Owns()
  • Deployment strategy defaults to RollingUpdate when scaling is enabled

Documentation

  • New "Horizontal Scaling with the Feast Operator" section in docs/how-to-guides/scaling-feast.md with static replicas, HPA, and KEDA examples
  • Updated docs/how-to-guides/feast-on-kubernetes.md with scaling references
  • Regenerated CRD API reference (ref.md) with new types
  • Sample CRs: v1_featurestore_scaling_static.yaml and v1_featurestore_scaling_hpa.yaml

Open with Devin

@ntkathole ntkathole self-assigned this Feb 21, 2026
@ntkathole ntkathole requested a review from a team as a code owner February 21, 2026 16:14
Copy link
Contributor

@devin-ai-integration devin-ai-integration bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Devin Review: No Issues Found

Devin Review analyzed this PR and found no potential bugs to report.

View in Devin Review to see 6 additional findings.

Open in Devin Review

Signed-off-by: ntkathole <nikhilkathole2683@gmail.com>
Copy link
Member

@franciscojavierarceo franciscojavierarceo left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It'd be good to do a blog post about scaling the feature server with KEDA.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants