diff --git a/output/openapi/elasticsearch-openapi.json b/output/openapi/elasticsearch-openapi.json index bb3b38463d..b6d2479062 100644 --- a/output/openapi/elasticsearch-openapi.json +++ b/output/openapi/elasticsearch-openapi.json @@ -70729,6 +70729,21 @@ "policy": { "$ref": "#/components/schemas/_types:Name" }, + "previous_step_info": { + "type": "object", + "additionalProperties": { + "type": "object" + } + }, + "repository_name": { + "type": "string" + }, + "snapshot_name": { + "type": "string" + }, + "shrink_index_name": { + "type": "string" + }, "step": { "$ref": "#/components/schemas/_types:Name" }, @@ -70752,14 +70767,17 @@ } }, "required": [ + "index", "managed", - "phase", - "policy" + "phase" ] }, "ilm.explain_lifecycle:LifecycleExplainPhaseExecution": { "type": "object", "properties": { + "phase_definition": { + "$ref": "#/components/schemas/ilm._types:Phase" + }, "policy": { "$ref": "#/components/schemas/_types:Name" }, @@ -70776,77 +70794,6 @@ "modified_date_in_millis" ] }, - "ilm.explain_lifecycle:LifecycleExplainUnmanaged": { - "type": "object", - "properties": { - "index": { - "$ref": "#/components/schemas/_types:IndexName" - }, - "managed": { - "type": "string", - "enum": [ - "false" - ] - } - }, - "required": [ - "index", - "managed" - ] - }, - "ilm.get_lifecycle:Lifecycle": { - "type": "object", - "properties": { - "modified_date": { - "$ref": "#/components/schemas/_types:DateTime" - }, - "policy": { - "$ref": "#/components/schemas/ilm._types:Policy" - }, - "version": { - "$ref": "#/components/schemas/_types:VersionNumber" - } - }, - "required": [ - "modified_date", - "policy", - "version" - ] - }, - "ilm._types:Policy": { - "type": "object", - "properties": { - "phases": { - "$ref": "#/components/schemas/ilm._types:Phases" - }, - "_meta": { - "$ref": "#/components/schemas/_types:Metadata" - } - }, - "required": [ - "phases" - ] - }, - "ilm._types:Phases": { - "type": "object", - "properties": { - "cold": { - "$ref": "#/components/schemas/ilm._types:Phase" - }, - "delete": { - "$ref": "#/components/schemas/ilm._types:Phase" - }, - "frozen": { - "$ref": "#/components/schemas/ilm._types:Phase" - }, - "hot": { - "$ref": "#/components/schemas/ilm._types:Phase" - }, - "warm": { - "$ref": "#/components/schemas/ilm._types:Phase" - } - } - }, "ilm._types:Phase": { "type": "object", "properties": { @@ -71057,6 +71004,77 @@ "policy" ] }, + "ilm.explain_lifecycle:LifecycleExplainUnmanaged": { + "type": "object", + "properties": { + "index": { + "$ref": "#/components/schemas/_types:IndexName" + }, + "managed": { + "type": "string", + "enum": [ + "false" + ] + } + }, + "required": [ + "index", + "managed" + ] + }, + "ilm.get_lifecycle:Lifecycle": { + "type": "object", + "properties": { + "modified_date": { + "$ref": "#/components/schemas/_types:DateTime" + }, + "policy": { + "$ref": "#/components/schemas/ilm._types:Policy" + }, + "version": { + "$ref": "#/components/schemas/_types:VersionNumber" + } + }, + "required": [ + "modified_date", + "policy", + "version" + ] + }, + "ilm._types:Policy": { + "type": "object", + "properties": { + "phases": { + "$ref": "#/components/schemas/ilm._types:Phases" + }, + "_meta": { + "$ref": "#/components/schemas/_types:Metadata" + } + }, + "required": [ + "phases" + ] + }, + "ilm._types:Phases": { + "type": "object", + "properties": { + "cold": { + "$ref": "#/components/schemas/ilm._types:Phase" + }, + "delete": { + "$ref": "#/components/schemas/ilm._types:Phase" + }, + "frozen": { + "$ref": "#/components/schemas/ilm._types:Phase" + }, + "hot": { + "$ref": "#/components/schemas/ilm._types:Phase" + }, + "warm": { + "$ref": "#/components/schemas/ilm._types:Phase" + } + } + }, "ilm.move_to_step:StepKey": { "type": "object", "properties": { diff --git a/output/schema/schema-serverless.json b/output/schema/schema-serverless.json index d2d4b16e79..d71b4a4dc8 100644 --- a/output/schema/schema-serverless.json +++ b/output/schema/schema-serverless.json @@ -95239,7 +95239,7 @@ "name": "LifecycleExplain", "namespace": "ilm.explain_lifecycle" }, - "specLocation": "ilm/explain_lifecycle/types.ts#L59-L62", + "specLocation": "ilm/explain_lifecycle/types.ts#L64-L67", "type": { "items": [ { @@ -95348,7 +95348,7 @@ }, { "name": "index", - "required": false, + "required": true, "type": { "kind": "instance_of", "type": { @@ -95482,7 +95482,7 @@ }, { "name": "policy", - "required": true, + "required": false, "type": { "kind": "instance_of", "type": { @@ -95491,6 +95491,57 @@ } } }, + { + "name": "previous_step_info", + "required": false, + "type": { + "key": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + }, + "kind": "dictionary_of", + "singleKey": false, + "value": { + "kind": "user_defined_value" + } + } + }, + { + "name": "repository_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "name": "snapshot_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "name": "shrink_index_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, { "name": "step", "required": false, @@ -95574,7 +95625,7 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L26-L52" + "specLocation": "ilm/explain_lifecycle/types.ts#L27-L57" }, { "kind": "interface", @@ -95583,6 +95634,17 @@ "namespace": "ilm.explain_lifecycle" }, "properties": [ + { + "name": "phase_definition", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Phase", + "namespace": "ilm._types" + } + } + }, { "name": "policy", "required": true, @@ -95626,7 +95688,650 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L64-L68" + "specLocation": "ilm/explain_lifecycle/types.ts#L69-L74" + }, + { + "kind": "interface", + "name": { + "name": "Phase", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "actions", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Actions", + "namespace": "ilm._types" + } + } + }, + { + "name": "min_age", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Duration", + "namespace": "_types" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L26-L29" + }, + { + "kind": "interface", + "name": { + "name": "Actions", + "namespace": "ilm._types" + }, + "properties": [ + { + "description": "Phases allowed: warm, cold.", + "name": "allocate", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "AllocateAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: delete.", + "name": "delete", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "DeleteAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, warm, cold.", + "name": "downsample", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "DownsampleAction", + "namespace": "ilm._types" + } + } + }, + { + "deprecation": { + "description": "", + "version": "7.0.0" + }, + "description": "The freeze action is a noop in 8.x", + "name": "freeze", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "EmptyObject", + "namespace": "_types" + } + } + }, + { + "description": "Phases allowed: hot, warm.", + "name": "forcemerge", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ForceMergeAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: warm, cold.", + "name": "migrate", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "MigrateAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, warm, cold.", + "name": "readonly", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "EmptyObject", + "namespace": "_types" + } + } + }, + { + "description": "Phases allowed: hot.", + "name": "rollover", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "RolloverAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, warm, cold.", + "name": "set_priority", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "SetPriorityAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, cold, frozen.", + "name": "searchable_snapshot", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "SearchableSnapshotAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, warm.", + "name": "shrink", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ShrinkAction", + "namespace": "ilm._types" + } + } + }, + { + "description": "Phases allowed: hot, warm, cold, frozen.", + "name": "unfollow", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "EmptyObject", + "namespace": "_types" + } + } + }, + { + "description": "Phases allowed: delete.", + "name": "wait_for_snapshot", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "WaitForSnapshotAction", + "namespace": "ilm._types" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L39-L93" + }, + { + "kind": "interface", + "name": { + "name": "AllocateAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "number_of_replicas", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + }, + { + "name": "total_shards_per_node", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + }, + { + "name": "include", + "required": false, + "type": { + "key": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + }, + "kind": "dictionary_of", + "singleKey": false, + "value": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + } + }, + { + "name": "exclude", + "required": false, + "type": { + "key": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + }, + "kind": "dictionary_of", + "singleKey": false, + "value": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + } + }, + { + "name": "require", + "required": false, + "type": { + "key": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + }, + "kind": "dictionary_of", + "singleKey": false, + "value": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L133-L139" + }, + { + "kind": "interface", + "name": { + "name": "DeleteAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "delete_searchable_snapshot", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "boolean", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L149-L151" + }, + { + "kind": "interface", + "name": { + "name": "DownsampleAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "fixed_interval", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "DurationLarge", + "namespace": "_types" + } + } + }, + { + "name": "wait_timeout", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Duration", + "namespace": "_types" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L112-L115" + }, + { + "kind": "interface", + "name": { + "name": "ForceMergeAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "max_num_segments", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + }, + { + "name": "index_codec", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L123-L126" + }, + { + "kind": "interface", + "name": { + "name": "MigrateAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "enabled", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "boolean", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L141-L143" + }, + { + "kind": "interface", + "name": { + "name": "RolloverAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "max_size", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ByteSize", + "namespace": "_types" + } + } + }, + { + "name": "max_primary_shard_size", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ByteSize", + "namespace": "_types" + } + } + }, + { + "name": "max_age", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Duration", + "namespace": "_types" + } + } + }, + { + "name": "max_docs", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "long", + "namespace": "_types" + } + } + }, + { + "name": "max_primary_shard_docs", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "long", + "namespace": "_types" + } + } + }, + { + "name": "min_size", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ByteSize", + "namespace": "_types" + } + } + }, + { + "name": "min_primary_shard_size", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ByteSize", + "namespace": "_types" + } + } + }, + { + "name": "min_age", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Duration", + "namespace": "_types" + } + } + }, + { + "name": "min_docs", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "long", + "namespace": "_types" + } + } + }, + { + "name": "min_primary_shard_docs", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "long", + "namespace": "_types" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L99-L110" + }, + { + "kind": "interface", + "name": { + "name": "SetPriorityAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "priority", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L95-L97" + }, + { + "kind": "interface", + "name": { + "name": "SearchableSnapshotAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "snapshot_repository", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "name": "force_merge_index", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "boolean", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L128-L131" + }, + { + "kind": "interface", + "name": { + "name": "ShrinkAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "number_of_shards", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + }, + { + "name": "max_primary_shard_size", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ByteSize", + "namespace": "_types" + } + } + }, + { + "name": "allow_write_after_shrink", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "boolean", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L117-L121" + }, + { + "kind": "interface", + "name": { + "name": "WaitForSnapshotAction", + "namespace": "ilm._types" + }, + "properties": [ + { + "name": "policy", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + } + ], + "specLocation": "ilm/_types/Phase.ts#L145-L147" }, { "kind": "interface", @@ -95655,7 +96360,7 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L54-L57" + "specLocation": "ilm/explain_lifecycle/types.ts#L59-L62" }, { "esQuirk": "This is a boolean that evolved into an enum. ES also accepts plain booleans for true and false.", diff --git a/output/schema/schema.json b/output/schema/schema.json index e04fb6515e..93b4f1f78a 100644 --- a/output/schema/schema.json +++ b/output/schema/schema.json @@ -126091,7 +126091,7 @@ "name": "LifecycleExplain", "namespace": "ilm.explain_lifecycle" }, - "specLocation": "ilm/explain_lifecycle/types.ts#L59-L62", + "specLocation": "ilm/explain_lifecycle/types.ts#L64-L67", "type": { "kind": "union_of", "items": [ @@ -126200,7 +126200,7 @@ }, { "name": "index", - "required": false, + "required": true, "type": { "kind": "instance_of", "type": { @@ -126334,7 +126334,7 @@ }, { "name": "policy", - "required": true, + "required": false, "type": { "kind": "instance_of", "type": { @@ -126343,6 +126343,57 @@ } } }, + { + "name": "previous_step_info", + "required": false, + "type": { + "kind": "dictionary_of", + "key": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + }, + "singleKey": false, + "value": { + "kind": "user_defined_value" + } + } + }, + { + "name": "repository_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "name": "snapshot_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "name": "shrink_index_name", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, { "name": "step", "required": false, @@ -126426,7 +126477,7 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L26-L52" + "specLocation": "ilm/explain_lifecycle/types.ts#L27-L57" }, { "kind": "interface", @@ -126435,6 +126486,17 @@ "namespace": "ilm.explain_lifecycle" }, "properties": [ + { + "name": "phase_definition", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Phase", + "namespace": "ilm._types" + } + } + }, { "name": "policy", "required": true, @@ -126478,7 +126540,7 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L64-L68" + "specLocation": "ilm/explain_lifecycle/types.ts#L69-L74" }, { "kind": "interface", @@ -126507,7 +126569,7 @@ } } ], - "specLocation": "ilm/explain_lifecycle/types.ts#L54-L57" + "specLocation": "ilm/explain_lifecycle/types.ts#L59-L62" }, { "kind": "request", diff --git a/output/typescript/types.ts b/output/typescript/types.ts index 7e7b7c662d..30c88281a1 100644 --- a/output/typescript/types.ts +++ b/output/typescript/types.ts @@ -10932,7 +10932,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { age?: Duration failed_step?: Name failed_step_retry_count?: integer - index?: IndexName + index: IndexName index_creation_date?: DateTime index_creation_date_millis?: EpochTime is_auto_retryable_error?: boolean @@ -10942,7 +10942,11 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { phase: Name phase_time?: DateTime phase_time_millis?: EpochTime - policy: Name + policy?: Name + previous_step_info?: Record + repository_name?: string + snapshot_name?: string + shrink_index_name?: string step?: Name step_info?: Record step_time?: DateTime @@ -10952,6 +10956,7 @@ export interface IlmExplainLifecycleLifecycleExplainManaged { } export interface IlmExplainLifecycleLifecycleExplainPhaseExecution { + phase_definition?: IlmPhase policy: Name version: VersionNumber modified_date_in_millis: EpochTime diff --git a/specification/ilm/explain_lifecycle/types.ts b/specification/ilm/explain_lifecycle/types.ts index d5a57ba4d6..871eaf239b 100644 --- a/specification/ilm/explain_lifecycle/types.ts +++ b/specification/ilm/explain_lifecycle/types.ts @@ -17,6 +17,7 @@ * under the License. */ +import { Phase } from '@ilm/_types/Phase' import { Dictionary } from '@spec_utils/Dictionary' import { UserDefinedValue } from '@spec_utils/UserDefinedValue' import { IndexName, Name, VersionNumber } from '@_types/common' @@ -31,7 +32,7 @@ export class LifecycleExplainManaged { age?: Duration failed_step?: Name failed_step_retry_count?: integer - index?: IndexName + index: IndexName index_creation_date?: DateTime index_creation_date_millis?: EpochTime is_auto_retryable_error?: boolean @@ -41,7 +42,11 @@ export class LifecycleExplainManaged { phase: Name phase_time?: DateTime phase_time_millis?: EpochTime - policy: Name + policy?: Name + previous_step_info?: Dictionary + repository_name?: string + snapshot_name?: string + shrink_index_name?: string step?: Name step_info?: Dictionary step_time?: DateTime @@ -62,6 +67,7 @@ export type LifecycleExplain = | LifecycleExplainUnmanaged export class LifecycleExplainPhaseExecution { + phase_definition?: Phase policy: Name version: VersionNumber modified_date_in_millis: EpochTime