Skip to content

Commit 0d18834

Browse files
committed
Add ml.get_model_snapshot_upgrade_stats (#1732)
* Add request & response for ml.get_model_snapshot_upgrade_stats * Make contrib * Upgrade ModelSnapshotUpgrade.status to enum * Fix typo
1 parent d57a087 commit 0d18834

File tree

6 files changed

+327
-7
lines changed

6 files changed

+327
-7
lines changed

output/schema/schema.json

Lines changed: 204 additions & 6 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

output/schema/validation-errors.json

Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

output/typescript/types.ts

Lines changed: 21 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

specification/ml/_types/Model.ts

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -20,6 +20,7 @@
2020
import { ByteSize, Id, VersionString } from '@_types/common'
2121
import { integer, long } from '@_types/Numeric'
2222
import { Time } from '@_types/Time'
23+
import { DiscoveryNode } from '@ml/_types/DiscoveryNode'
2324

2425
export class ModelSnapshot {
2526
/** An optional description of the job. */
@@ -44,6 +45,14 @@ export class ModelSnapshot {
4445
timestamp: long
4546
}
4647

48+
export class ModelSnapshotUpgrade {
49+
job_id: Id
50+
snapshot_id: Id
51+
state: SnapshotUpgradeState
52+
node: DiscoveryNode
53+
assignment_explanation: string
54+
}
55+
4756
export class ModelSizeStats {
4857
bucket_allocation_failures_count: long
4958
job_id: Id
@@ -78,3 +87,10 @@ export enum MemoryStatus {
7887
soft_limit,
7988
hard_limit
8089
}
90+
91+
export enum SnapshotUpgradeState {
92+
loading_old_state,
93+
saving_new_state,
94+
stopped,
95+
failed
96+
}

0 commit comments

Comments
 (0)