diff --git a/output/schema/schema.json b/output/schema/schema.json index 341ba91636..41facc795d 100644 --- a/output/schema/schema.json +++ b/output/schema/schema.json @@ -32219,7 +32219,7 @@ "name": "DateFormat", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L37-L38", + "specLocation": "_types/Time.ts#L30-L31", "type": { "kind": "instance_of", "type": { @@ -32234,7 +32234,7 @@ "name": "DateMath", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L31-L31", + "specLocation": "_types/Time.ts#L25-L25", "type": { "kind": "instance_of", "type": { @@ -32249,7 +32249,7 @@ "name": "DateMathTime", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L33-L33", + "specLocation": "_types/Time.ts#L26-L26", "type": { "kind": "instance_of", "type": { @@ -32264,7 +32264,7 @@ "name": "DateString", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L27-L27", + "specLocation": "_types/Time.ts#L21-L21", "type": { "kind": "instance_of", "type": { @@ -32510,7 +32510,7 @@ "name": "EpochMillis", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L30-L30", + "specLocation": "_types/Time.ts#L24-L24", "type": { "items": [ { @@ -35551,7 +35551,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36446,7 +36446,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36490,7 +36490,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36512,7 +36512,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36523,7 +36523,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36556,7 +36556,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36578,7 +36578,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36600,7 +36600,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36622,7 +36622,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36633,7 +36633,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36666,7 +36666,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -36688,7 +36688,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -37198,7 +37198,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -37220,7 +37220,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -37242,7 +37242,7 @@ "type": { "kind": "instance_of", "type": { - "name": "integer", + "name": "long", "namespace": "_types" } } @@ -37424,7 +37424,7 @@ "name": "Time", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L62-L68", + "specLocation": "_types/Time.ts#L33-L39", "type": { "items": [ { @@ -37451,7 +37451,7 @@ "name": "TimeSpan", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L29-L29", + "specLocation": "_types/Time.ts#L23-L23", "type": { "kind": "instance_of", "type": { @@ -37496,7 +37496,7 @@ "name": "TimeUnit", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L70-L85" + "specLocation": "_types/Time.ts#L41-L56" }, { "kind": "type_alias", @@ -37504,7 +37504,7 @@ "name": "TimeZone", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L35-L35", + "specLocation": "_types/Time.ts#L28-L28", "type": { "kind": "instance_of", "type": { @@ -37519,7 +37519,7 @@ "name": "Timestamp", "namespace": "_types" }, - "specLocation": "_types/Time.ts#L28-L28", + "specLocation": "_types/Time.ts#L22-L22", "type": { "kind": "instance_of", "type": { @@ -38310,7 +38310,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L48-L50" + "specLocation": "_types/aggregations/bucket.ts#L55-L57" }, { "attachedBehaviors": [ @@ -38855,7 +38855,7 @@ "name": "AggregateOrder", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L370-L372", + "specLocation": "_types/aggregations/bucket.ts#L409-L411", "type": { "items": [ { @@ -39835,7 +39835,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L268-L272" + "specLocation": "_types/aggregations/bucket.ts#L307-L311" }, { "kind": "interface", @@ -40049,7 +40049,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L52-L62" + "specLocation": "_types/aggregations/bucket.ts#L59-L69" }, { "inherits": { @@ -40309,7 +40309,7 @@ "namespace": "_types.aggregations" }, "properties": [], - "specLocation": "_types/aggregations/bucket.ts#L41-L46" + "specLocation": "_types/aggregations/bucket.ts#L48-L53" }, { "inherits": { @@ -40618,7 +40618,7 @@ "name": "CalendarInterval", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L111-L128" + "specLocation": "_types/aggregations/bucket.ts#L150-L167" }, { "inherits": { @@ -40716,7 +40716,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L292-L295" + "specLocation": "_types/aggregations/bucket.ts#L331-L334" }, { "attachedBehaviors": [ @@ -40762,7 +40762,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L73-L75" + "specLocation": "_types/aggregations/bucket.ts#L80-L82" }, { "kind": "interface", @@ -40878,7 +40878,7 @@ "name": "CompositeAggregateKey", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L77-L77", + "specLocation": "_types/aggregations/bucket.ts#L84-L84", "type": { "key": { "kind": "instance_of", @@ -40959,7 +40959,85 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L79-L84" + "specLocation": "_types/aggregations/bucket.ts#L86-L91" + }, + { + "kind": "interface", + "name": { + "name": "CompositeAggregationBase", + "namespace": "_types.aggregations" + }, + "properties": [ + { + "description": "Either `field` or `script` must be present", + "name": "field", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Field", + "namespace": "_types" + } + } + }, + { + "name": "missing_bucket", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "boolean", + "namespace": "_builtins" + } + } + }, + { + "name": "missing_order", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "MissingOrder", + "namespace": "_types.aggregations" + } + } + }, + { + "description": "Either `field` or `script` must be present", + "name": "script", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Script", + "namespace": "_types" + } + } + }, + { + "name": "value_type", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "ValueType", + "namespace": "_types.aggregations" + } + } + }, + { + "name": "order", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "SortOrder", + "namespace": "_types" + } + } + } + ], + "specLocation": "_types/aggregations/bucket.ts#L100-L109" }, { "kind": "interface", @@ -40974,7 +41052,7 @@ "type": { "kind": "instance_of", "type": { - "name": "TermsAggregation", + "name": "CompositeTermsAggregation", "namespace": "_types.aggregations" } } @@ -40985,7 +41063,7 @@ "type": { "kind": "instance_of", "type": { - "name": "HistogramAggregation", + "name": "CompositeHistogramAggregation", "namespace": "_types.aggregations" } } @@ -40996,7 +41074,7 @@ "type": { "kind": "instance_of", "type": { - "name": "DateHistogramAggregation", + "name": "CompositeDateHistogramAggregation", "namespace": "_types.aggregations" } } @@ -41007,13 +41085,13 @@ "type": { "kind": "instance_of", "type": { - "name": "GeoTileGridAggregation", + "name": "CompositeGeoTileGridAggregation", "namespace": "_types.aggregations" } } } ], - "specLocation": "_types/aggregations/bucket.ts#L86-L91" + "specLocation": "_types/aggregations/bucket.ts#L93-L98" }, { "attachedBehaviors": [ @@ -41045,6 +41123,159 @@ ], "specLocation": "_types/aggregations/Aggregate.ts#L608-L610" }, + { + "inherits": { + "type": { + "name": "CompositeAggregationBase", + "namespace": "_types.aggregations" + } + }, + "kind": "interface", + "name": { + "name": "CompositeDateHistogramAggregation", + "namespace": "_types.aggregations" + }, + "properties": [ + { + "name": "format", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "string", + "namespace": "_builtins" + } + } + }, + { + "description": "Either `calendar_interval` or `fixed_interval` must be present", + "name": "calendar_interval", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "DateMathTime", + "namespace": "_types" + } + } + }, + { + "description": "Either `calendar_interval` or `fixed_interval` must be present", + "name": "fixed_interval", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "DateMathTime", + "namespace": "_types" + } + } + }, + { + "name": "offset", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "Time", + "namespace": "_types" + } + } + }, + { + "name": "time_zone", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "TimeZone", + "namespace": "_types" + } + } + } + ], + "specLocation": "_types/aggregations/bucket.ts#L117-L125" + }, + { + "inherits": { + "type": { + "name": "CompositeAggregationBase", + "namespace": "_types.aggregations" + } + }, + "kind": "interface", + "name": { + "name": "CompositeGeoTileGridAggregation", + "namespace": "_types.aggregations" + }, + "properties": [ + { + "name": "precision", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "integer", + "namespace": "_types" + } + } + }, + { + "name": "bounds", + "required": false, + "type": { + "kind": "instance_of", + "type": { + "name": "GeoBounds", + "namespace": "_types" + } + } + } + ], + "specLocation": "_types/aggregations/bucket.ts#L127-L130" + }, + { + "inherits": { + "type": { + "name": "CompositeAggregationBase", + "namespace": "_types.aggregations" + } + }, + "kind": "interface", + "name": { + "name": "CompositeHistogramAggregation", + "namespace": "_types.aggregations" + }, + "properties": [ + { + "name": "interval", + "required": true, + "type": { + "kind": "instance_of", + "type": { + "name": "double", + "namespace": "_types" + } + } + } + ], + "specLocation": "_types/aggregations/bucket.ts#L113-L115" + }, + { + "inherits": { + "type": { + "name": "CompositeAggregationBase", + "namespace": "_types.aggregations" + } + }, + "kind": "interface", + "name": { + "name": "CompositeTermsAggregation", + "namespace": "_types.aggregations" + }, + "properties": [], + "specLocation": "_types/aggregations/bucket.ts#L111-L111" + }, { "description": "Result of the `cumulative_cardinality` aggregation", "inherits": { @@ -41344,7 +41575,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L93-L109" + "specLocation": "_types/aggregations/bucket.ts#L132-L148" }, { "attachedBehaviors": [ @@ -41487,7 +41718,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L130-L137" + "specLocation": "_types/aggregations/bucket.ts#L169-L176" }, { "kind": "interface", @@ -41530,7 +41761,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L148-L152" + "specLocation": "_types/aggregations/bucket.ts#L187-L191" }, { "inherits": { @@ -41655,7 +41886,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L154-L160" + "specLocation": "_types/aggregations/bucket.ts#L193-L199" }, { "description": "Result of a `terms` aggregation when the field is some kind of decimal number like a float, double, or distance.", @@ -41816,7 +42047,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L201-L204" + "specLocation": "_types/aggregations/bucket.ts#L240-L243" }, { "inherits": { @@ -42154,7 +42385,7 @@ "name": "FieldDateMath", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L139-L146", + "specLocation": "_types/aggregations/bucket.ts#L178-L185", "type": { "items": [ { @@ -42286,7 +42517,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L168-L173" + "specLocation": "_types/aggregations/bucket.ts#L207-L212" }, { "attachedBehaviors": [ @@ -42603,7 +42834,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L175-L181" + "specLocation": "_types/aggregations/bucket.ts#L214-L220" }, { "inherits": { @@ -42699,7 +42930,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L183-L189" + "specLocation": "_types/aggregations/bucket.ts#L222-L228" }, { "attachedBehaviors": [ @@ -42978,7 +43209,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L191-L197" + "specLocation": "_types/aggregations/bucket.ts#L230-L236" }, { "attachedBehaviors": [ @@ -43042,7 +43273,7 @@ "namespace": "_types.aggregations" }, "properties": [], - "specLocation": "_types/aggregations/bucket.ts#L199-L199" + "specLocation": "_types/aggregations/bucket.ts#L238-L238" }, { "kind": "interface", @@ -43063,7 +43294,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L297-L299" + "specLocation": "_types/aggregations/bucket.ts#L336-L338" }, { "kind": "interface", @@ -43296,7 +43527,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L206-L218" + "specLocation": "_types/aggregations/bucket.ts#L245-L257" }, { "attachedBehaviors": [ @@ -43882,7 +44113,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L220-L223" + "specLocation": "_types/aggregations/bucket.ts#L259-L262" }, { "kind": "interface", @@ -43925,7 +44156,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L225-L229" + "specLocation": "_types/aggregations/bucket.ts#L264-L268" }, { "attachedBehaviors": [ @@ -44635,7 +44866,7 @@ "name": "MinimumInterval", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L64-L71" + "specLocation": "_types/aggregations/bucket.ts#L71-L78" }, { "kind": "type_alias", @@ -44733,7 +44964,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L231-L234" + "specLocation": "_types/aggregations/bucket.ts#L270-L273" }, { "kind": "enum", @@ -45074,7 +45305,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L247-L250" + "specLocation": "_types/aggregations/bucket.ts#L286-L289" }, { "inherits": { @@ -45206,7 +45437,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L236-L245" + "specLocation": "_types/aggregations/bucket.ts#L275-L284" }, { "attachedBehaviors": [ @@ -45293,7 +45524,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L301-L304" + "specLocation": "_types/aggregations/bucket.ts#L340-L343" }, { "attachedBehaviors": [ @@ -45339,7 +45570,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L252-L254" + "specLocation": "_types/aggregations/bucket.ts#L291-L293" }, { "inherits": { @@ -45441,7 +45672,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L256-L258" + "specLocation": "_types/aggregations/bucket.ts#L295-L297" }, { "kind": "interface", @@ -45450,7 +45681,7 @@ "namespace": "_types.aggregations" }, "properties": [], - "specLocation": "_types/aggregations/bucket.ts#L306-L306" + "specLocation": "_types/aggregations/bucket.ts#L345-L345" }, { "inherits": { @@ -45843,7 +46074,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L260-L266" + "specLocation": "_types/aggregations/bucket.ts#L299-L305" }, { "attachedBehaviors": [ @@ -46011,7 +46242,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L274-L282" + "specLocation": "_types/aggregations/bucket.ts#L313-L321" }, { "inherits": { @@ -46185,7 +46416,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L284-L286" + "specLocation": "_types/aggregations/bucket.ts#L323-L325" }, { "attachedBehaviors": [ @@ -46231,7 +46462,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L288-L290" + "specLocation": "_types/aggregations/bucket.ts#L327-L329" }, { "kind": "enum", @@ -46250,7 +46481,7 @@ "name": "SamplerAggregationExecutionHint", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L162-L166" + "specLocation": "_types/aggregations/bucket.ts#L201-L205" }, { "kind": "interface", @@ -46271,7 +46502,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L308-L310" + "specLocation": "_types/aggregations/bucket.ts#L347-L349" }, { "inherits": { @@ -46744,7 +46975,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L312-L327" + "specLocation": "_types/aggregations/bucket.ts#L351-L366" }, { "attachedBehaviors": [ @@ -46977,7 +47208,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L329-L346" + "specLocation": "_types/aggregations/bucket.ts#L368-L385" }, { "inherits": { @@ -48336,7 +48567,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L348-L364" + "specLocation": "_types/aggregations/bucket.ts#L387-L403" }, { "kind": "enum", @@ -48352,7 +48583,7 @@ "name": "TermsAggregationCollectMode", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L374-L377" + "specLocation": "_types/aggregations/bucket.ts#L413-L416" }, { "kind": "enum", @@ -48374,7 +48605,7 @@ "name": "TermsAggregationExecutionHint", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L379-L384" + "specLocation": "_types/aggregations/bucket.ts#L418-L423" }, { "attachedBehaviors": [ @@ -48416,7 +48647,7 @@ "name": "TermsExclude", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L389-L390", + "specLocation": "_types/aggregations/bucket.ts#L428-L429", "type": { "items": [ { @@ -48451,7 +48682,7 @@ "name": "TermsInclude", "namespace": "_types.aggregations" }, - "specLocation": "_types/aggregations/bucket.ts#L386-L387", + "specLocation": "_types/aggregations/bucket.ts#L425-L426", "type": { "items": [ { @@ -48512,7 +48743,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L392-L395" + "specLocation": "_types/aggregations/bucket.ts#L431-L434" }, { "kind": "interface", @@ -49181,7 +49412,7 @@ } } ], - "specLocation": "_types/aggregations/bucket.ts#L397-L402" + "specLocation": "_types/aggregations/bucket.ts#L436-L441" }, { "attachedBehaviors": [ @@ -52913,7 +53144,7 @@ }, { "name": "flags", - "required": true, + "required": false, "type": { "kind": "instance_of", "type": { @@ -52924,7 +53155,7 @@ }, { "name": "group", - "required": true, + "required": false, "type": { "kind": "instance_of", "type": { @@ -52935,7 +53166,7 @@ }, { "name": "pattern", - "required": true, + "required": false, "type": { "kind": "instance_of", "type": { diff --git a/output/typescript/types.ts b/output/typescript/types.ts index 8a0643a4e3..f9f321443d 100644 --- a/output/typescript/types.ts +++ b/output/typescript/types.ts @@ -2235,7 +2235,7 @@ export interface QueryCacheStats { evictions: integer hit_count: integer memory_size?: ByteSize - memory_size_in_bytes: integer + memory_size_in_bytes: long miss_count: integer total_count: integer } @@ -2341,28 +2341,28 @@ export type SearchType = 'query_then_fetch' | 'dfs_query_then_fetch' export interface SegmentsStats { count: integer doc_values_memory?: ByteSize - doc_values_memory_in_bytes: integer + doc_values_memory_in_bytes: long file_sizes: Record fixed_bit_set?: ByteSize - fixed_bit_set_memory_in_bytes: integer + fixed_bit_set_memory_in_bytes: long index_writer_memory?: ByteSize - index_writer_max_memory_in_bytes?: integer - index_writer_memory_in_bytes: integer + index_writer_max_memory_in_bytes?: long + index_writer_memory_in_bytes: long max_unsafe_auto_id_timestamp: long memory?: ByteSize - memory_in_bytes: integer + memory_in_bytes: long norms_memory?: ByteSize - norms_memory_in_bytes: integer + norms_memory_in_bytes: long points_memory?: ByteSize - points_memory_in_bytes: integer + points_memory_in_bytes: long stored_memory?: ByteSize - stored_fields_memory_in_bytes: integer - terms_memory_in_bytes: integer + stored_fields_memory_in_bytes: long + terms_memory_in_bytes: long terms_memory?: ByteSize term_vectory_memory?: ByteSize - term_vectors_memory_in_bytes: integer + term_vectors_memory_in_bytes: long version_map_memory?: ByteSize - version_map_memory_in_bytes: integer + version_map_memory_in_bytes: long } export type SequenceNumber = long @@ -2420,11 +2420,11 @@ export type SortResults = FieldValue[] export interface StoreStats { size?: ByteSize - size_in_bytes: integer + size_in_bytes: long reserved?: ByteSize - reserved_in_bytes: integer + reserved_in_bytes: long total_data_set_size?: ByteSize - total_data_set_size_in_bytes?: integer + total_data_set_size_in_bytes?: long } export interface StoredScript { @@ -2773,11 +2773,20 @@ export interface AggregationsCompositeAggregation extends AggregationsBucketAggr sources?: Record[] } +export interface AggregationsCompositeAggregationBase { + field?: Field + missing_bucket?: boolean + missing_order?: AggregationsMissingOrder + script?: Script + value_type?: AggregationsValueType + order?: SortOrder +} + export interface AggregationsCompositeAggregationSource { - terms?: AggregationsTermsAggregation - histogram?: AggregationsHistogramAggregation - date_histogram?: AggregationsDateHistogramAggregation - geotile_grid?: AggregationsGeoTileGridAggregation + terms?: AggregationsCompositeTermsAggregation + histogram?: AggregationsCompositeHistogramAggregation + date_histogram?: AggregationsCompositeDateHistogramAggregation + geotile_grid?: AggregationsCompositeGeoTileGridAggregation } export interface AggregationsCompositeBucketKeys extends AggregationsMultiBucketBase { @@ -2786,6 +2795,26 @@ export interface AggregationsCompositeBucketKeys extends AggregationsMultiBucket export type AggregationsCompositeBucket = AggregationsCompositeBucketKeys & { [property: string]: AggregationsAggregate | AggregationsCompositeAggregateKey | long } +export interface AggregationsCompositeDateHistogramAggregation extends AggregationsCompositeAggregationBase { + format?: string + calendar_interval?: DateMathTime + fixed_interval?: DateMathTime + offset?: Time + time_zone?: TimeZone +} + +export interface AggregationsCompositeGeoTileGridAggregation extends AggregationsCompositeAggregationBase { + precision?: integer + bounds?: GeoBounds +} + +export interface AggregationsCompositeHistogramAggregation extends AggregationsCompositeAggregationBase { + interval: double +} + +export interface AggregationsCompositeTermsAggregation extends AggregationsCompositeAggregationBase { +} + export interface AggregationsCumulativeCardinalityAggregate extends AggregationsAggregateBase { value: long value_as_string?: string @@ -4203,9 +4232,9 @@ export interface AnalysisPatternReplaceTokenFilter extends AnalysisTokenFilterBa export interface AnalysisPatternTokenizer extends AnalysisTokenizerBase { type: 'pattern' - flags: string - group: integer - pattern: string + flags?: string + group?: integer + pattern?: string } export type AnalysisPhoneticEncoder = 'metaphone' | 'double_metaphone' | 'soundex' | 'refined_soundex' | 'caverphone1' | 'caverphone2' | 'cologne' | 'nysiis' | 'koelnerphonetik' | 'haasephonetik' | 'beider_morse' | 'daitch_mokotoff' diff --git a/specification/_types/Stats.ts b/specification/_types/Stats.ts index f6f2e83584..b3acfe8418 100644 --- a/specification/_types/Stats.ts +++ b/specification/_types/Stats.ts @@ -152,7 +152,7 @@ export class QueryCacheStats { evictions: integer hit_count: integer memory_size?: ByteSize - memory_size_in_bytes: integer + memory_size_in_bytes: long miss_count: integer total_count: integer } @@ -201,37 +201,37 @@ export class SearchStats { export class SegmentsStats { count: integer doc_values_memory?: ByteSize - doc_values_memory_in_bytes: integer + doc_values_memory_in_bytes: long file_sizes: Dictionary fixed_bit_set?: ByteSize - fixed_bit_set_memory_in_bytes: integer + fixed_bit_set_memory_in_bytes: long index_writer_memory?: ByteSize - index_writer_max_memory_in_bytes?: integer - index_writer_memory_in_bytes: integer + index_writer_max_memory_in_bytes?: long + index_writer_memory_in_bytes: long max_unsafe_auto_id_timestamp: long memory?: ByteSize - memory_in_bytes: integer + memory_in_bytes: long norms_memory?: ByteSize - norms_memory_in_bytes: integer + norms_memory_in_bytes: long points_memory?: ByteSize - points_memory_in_bytes: integer + points_memory_in_bytes: long stored_memory?: ByteSize - stored_fields_memory_in_bytes: integer - terms_memory_in_bytes: integer + stored_fields_memory_in_bytes: long + terms_memory_in_bytes: long terms_memory?: ByteSize term_vectory_memory?: ByteSize - term_vectors_memory_in_bytes: integer + term_vectors_memory_in_bytes: long version_map_memory?: ByteSize - version_map_memory_in_bytes: integer + version_map_memory_in_bytes: long } export class StoreStats { size?: ByteSize - size_in_bytes: integer + size_in_bytes: long reserved?: ByteSize - reserved_in_bytes: integer + reserved_in_bytes: long total_data_set_size?: ByteSize - total_data_set_size_in_bytes?: integer + total_data_set_size_in_bytes?: long } export class TranslogStats { diff --git a/specification/_types/Time.ts b/specification/_types/Time.ts index 2b5826a88c..9f9b0d6064 100644 --- a/specification/_types/Time.ts +++ b/specification/_types/Time.ts @@ -18,18 +18,11 @@ */ import { integer, long } from './Numeric' - -export class DateMathTimeParsed { - factor: integer - interval: DateMathTimeUnit -} - export type DateString = string export type Timestamp = string export type TimeSpan = string export type EpochMillis = string | long export type DateMath = string -export type DateMathExpression = string export type DateMathTime = string export type TimeZone = string @@ -37,28 +30,6 @@ export type TimeZone = string /** @doc_url https://www.elastic.co/guide/en/elasticsearch/reference/7.x/mapping-date-format.html */ export type DateFormat = string -export enum DateMathOperation { - '+' = 0, - '-' = 1 -} - -export enum DateMathTimeUnit { - /** @codegen_name seconds */ - s = 0, - /** @codegen_name minutes */ - m = 1, - /** @codegen_name hours */ - h = 2, - /** @codegen_name days */ - d = 3, - /** @codegen_name weeks */ - w = 4, - /** @codegen_name months */ - M = 5, - /** @codegen_name years */ - y = 6 -} - /** * Whenever durations need to be specified, e.g. for a timeout parameter, the duration must specify the unit, like 2d for 2 days. * @doc_url https://github.com/elastic/elasticsearch/blob/master/libs/core/src/main/java/org/elasticsearch/core/TimeValue.java diff --git a/specification/_types/aggregations/bucket.ts b/specification/_types/aggregations/bucket.ts index f33f2944cb..417ede5ba6 100644 --- a/specification/_types/aggregations/bucket.ts +++ b/specification/_types/aggregations/bucket.ts @@ -33,10 +33,17 @@ import { import { integer, float, long, double } from '@_types/Numeric' import { QueryContainer } from '@_types/query_dsl/abstractions' import { Script } from '@_types/Scripting' -import { DateString, Time, DateMath } from '@_types/Time' +import { + DateString, + Time, + DateMath, + TimeZone, + DateMathTime +} from '@_types/Time' import { Buckets } from './Aggregate' import { Aggregation } from './Aggregation' import { Missing, MissingOrder } from './AggregationContainer' +import { ValueType } from '@_types/aggregations/metric' /** * Base type for bucket aggregations. These aggregations also accept sub-aggregations. @@ -84,10 +91,42 @@ export class CompositeAggregation extends BucketAggregationBase { } export class CompositeAggregationSource { - terms?: TermsAggregation - histogram?: HistogramAggregation - date_histogram?: DateHistogramAggregation - geotile_grid?: GeoTileGridAggregation + terms?: CompositeTermsAggregation + histogram?: CompositeHistogramAggregation + date_histogram?: CompositeDateHistogramAggregation + geotile_grid?: CompositeGeoTileGridAggregation +} + +export class CompositeAggregationBase { + /** Either `field` or `script` must be present */ + field?: Field + missing_bucket?: boolean + missing_order?: MissingOrder + /** Either `field` or `script` must be present */ + script?: Script + value_type?: ValueType + order?: SortOrder +} + +export class CompositeTermsAggregation extends CompositeAggregationBase {} + +export class CompositeHistogramAggregation extends CompositeAggregationBase { + interval: double +} + +export class CompositeDateHistogramAggregation extends CompositeAggregationBase { + format?: string + /** Either `calendar_interval` or `fixed_interval` must be present */ + calendar_interval?: DateMathTime + /** Either `calendar_interval` or `fixed_interval` must be present */ + fixed_interval?: DateMathTime + offset?: Time + time_zone?: TimeZone +} + +export class CompositeGeoTileGridAggregation extends CompositeAggregationBase { + precision?: integer + bounds?: GeoBounds } export class DateHistogramAggregation extends BucketAggregationBase { diff --git a/specification/_types/analysis/tokenizers.ts b/specification/_types/analysis/tokenizers.ts index ec5a5e952d..6141ac178a 100644 --- a/specification/_types/analysis/tokenizers.ts +++ b/specification/_types/analysis/tokenizers.ts @@ -96,9 +96,9 @@ export class PathHierarchyTokenizer extends TokenizerBase { export class PatternTokenizer extends TokenizerBase { type: 'pattern' - flags: string - group: integer - pattern: string + flags?: string + group?: integer + pattern?: string } export class StandardTokenizer extends TokenizerBase {