Finish autoscaling diagnostics and document pilot rollout
This commit is contained in:
@@ -22,6 +22,7 @@ export function ensureAutoscalingSchema(handle: Database.Database): void {
|
||||
);
|
||||
CREATE UNIQUE INDEX IF NOT EXISTS autoscaling_one_intent ON autoscaling_decisions(policy_id) WHERE resolved=0;
|
||||
CREATE INDEX IF NOT EXISTS autoscaling_history ON autoscaling_decisions(policy_id,evaluated_at DESC);
|
||||
CREATE INDEX IF NOT EXISTS autoscaling_decision_retention ON autoscaling_decisions(last_seen_at) WHERE resolved=1;
|
||||
CREATE TABLE IF NOT EXISTS autoscaling_samples (
|
||||
policy_id TEXT NOT NULL REFERENCES autoscaling_policies(id), sampled_at INTEGER NOT NULL,
|
||||
mode TEXT NOT NULL, occupied INTEGER NOT NULL, empty INTEGER NOT NULL, unknown INTEGER NOT NULL,
|
||||
@@ -31,5 +32,6 @@ export function ensureAutoscalingSchema(handle: Database.Database): void {
|
||||
operation_id TEXT PRIMARY KEY, policy_id TEXT NOT NULL, revision INTEGER NOT NULL,
|
||||
expires_at INTEGER NOT NULL, claimed_at INTEGER, revoked_at INTEGER
|
||||
);
|
||||
CREATE INDEX IF NOT EXISTS autoscaling_sample_retention ON autoscaling_samples(sampled_at);
|
||||
`);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user