neondatabase / autoscaling

Postgres vertical autoscaling in k8s
Apache License 2.0
153 stars 21 forks source link

plugin: Transaction-based speculative reserve and logic unification #936

Closed sharnoff closed 3 months ago

sharnoff commented 4 months ago

Trying out this approach as a potential way to make implementing overcommit (#517) easier, to avoid dealing with rounding errors when responding to the autoscaler-agents.

I think this "speculative reserve" may be a reasonable change in isolation, and reducing the number of separate implementations of the same logic should also help with overcommit (because of how it affects every single resource calculation).

Not 100% sure we want to go this route, but it's my best guess so far.


Tested this locally and it seemed to be ok; already fixed a couple bugs based on suspicious logs. There might be more.

sharnoff commented 3 months ago

Updates: