Skip to content

Commit abdb2b3

Browse files
authored
regen (#986)
1 parent baa74a3 commit abdb2b3

File tree

3 files changed

+317
-29
lines changed

3 files changed

+317
-29
lines changed

java-client/src/main/java/co/elastic/clients/elasticsearch/doc-files/api-spec.html

+30-29
Original file line numberDiff line numberDiff line change
@@ -1747,45 +1747,46 @@
17471747
'ingest._types.GrokProcessor': 'ingest/_types/Processors.ts#L950-L981',
17481748
'ingest._types.GsubProcessor': 'ingest/_types/Processors.ts#L983-L1007',
17491749
'ingest._types.HtmlStripProcessor': 'ingest/_types/Processors.ts#L1009-L1025',
1750-
'ingest._types.InferenceConfig': 'ingest/_types/Processors.ts#L1048-L1060',
1751-
'ingest._types.InferenceConfigClassification': 'ingest/_types/Processors.ts#L1075-L1101',
1752-
'ingest._types.InferenceConfigRegression': 'ingest/_types/Processors.ts#L1062-L1073',
1753-
'ingest._types.InferenceProcessor': 'ingest/_types/Processors.ts#L1027-L1046',
1750+
'ingest._types.InferenceConfig': 'ingest/_types/Processors.ts#L1066-L1078',
1751+
'ingest._types.InferenceConfigClassification': 'ingest/_types/Processors.ts#L1093-L1119',
1752+
'ingest._types.InferenceConfigRegression': 'ingest/_types/Processors.ts#L1080-L1091',
1753+
'ingest._types.InferenceProcessor': 'ingest/_types/Processors.ts#L1027-L1059',
17541754
'ingest._types.Ingest': 'ingest/_types/Simulation.ts#L29-L37',
1755+
'ingest._types.InputConfig': 'ingest/_types/Processors.ts#L1061-L1064',
17551756
'ingest._types.IpLocationProcessor': 'ingest/_types/Processors.ts#L478-L512',
17561757
'ingest._types.Ipinfo': 'ingest/_types/Database.ts#L59-L59',
1757-
'ingest._types.JoinProcessor': 'ingest/_types/Processors.ts#L1103-L1118',
1758-
'ingest._types.JsonProcessor': 'ingest/_types/Processors.ts#L1120-L1149',
1759-
'ingest._types.JsonProcessorConflictStrategy': 'ingest/_types/Processors.ts#L1151-L1156',
1760-
'ingest._types.KeyValueProcessor': 'ingest/_types/Processors.ts#L1158-L1210',
1758+
'ingest._types.JoinProcessor': 'ingest/_types/Processors.ts#L1121-L1136',
1759+
'ingest._types.JsonProcessor': 'ingest/_types/Processors.ts#L1138-L1167',
1760+
'ingest._types.JsonProcessorConflictStrategy': 'ingest/_types/Processors.ts#L1169-L1174',
1761+
'ingest._types.KeyValueProcessor': 'ingest/_types/Processors.ts#L1176-L1228',
17611762
'ingest._types.Local': 'ingest/_types/Database.ts#L63-L65',
1762-
'ingest._types.LowercaseProcessor': 'ingest/_types/Processors.ts#L1212-L1228',
1763+
'ingest._types.LowercaseProcessor': 'ingest/_types/Processors.ts#L1230-L1246',
17631764
'ingest._types.Maxmind': 'ingest/_types/Database.ts#L55-L57',
1764-
'ingest._types.NetworkDirectionProcessor': 'ingest/_types/Processors.ts#L1230-L1264',
1765+
'ingest._types.NetworkDirectionProcessor': 'ingest/_types/Processors.ts#L1248-L1282',
17651766
'ingest._types.Pipeline': 'ingest/_types/Pipeline.ts#L23-L51',
17661767
'ingest._types.PipelineConfig': 'ingest/_types/Pipeline.ts#L67-L81',
1767-
'ingest._types.PipelineProcessor': 'ingest/_types/Processors.ts#L1266-L1277',
1768+
'ingest._types.PipelineProcessor': 'ingest/_types/Processors.ts#L1284-L1295',
17681769
'ingest._types.PipelineSimulation': 'ingest/_types/Simulation.ts#L52-L60',
17691770
'ingest._types.ProcessorBase': 'ingest/_types/Processors.ts#L303-L326',
17701771
'ingest._types.ProcessorContainer': 'ingest/_types/Processors.ts#L27-L301',
17711772
'ingest._types.Redact': 'ingest/_types/Simulation.ts#L39-L44',
1772-
'ingest._types.RedactProcessor': 'ingest/_types/Processors.ts#L1279-L1320',
1773-
'ingest._types.RegisteredDomainProcessor': 'ingest/_types/Processors.ts#L1322-L1338',
1774-
'ingest._types.RemoveProcessor': 'ingest/_types/Processors.ts#L1340-L1354',
1775-
'ingest._types.RenameProcessor': 'ingest/_types/Processors.ts#L1356-L1372',
1776-
'ingest._types.RerouteProcessor': 'ingest/_types/Processors.ts#L1374-L1402',
1777-
'ingest._types.ScriptProcessor': 'ingest/_types/Processors.ts#L1404-L1424',
1778-
'ingest._types.SetProcessor': 'ingest/_types/Processors.ts#L1426-L1460',
1779-
'ingest._types.SetSecurityUserProcessor': 'ingest/_types/Processors.ts#L1462-L1471',
1780-
'ingest._types.ShapeType': 'ingest/_types/Processors.ts#L1473-L1476',
1773+
'ingest._types.RedactProcessor': 'ingest/_types/Processors.ts#L1297-L1338',
1774+
'ingest._types.RegisteredDomainProcessor': 'ingest/_types/Processors.ts#L1340-L1356',
1775+
'ingest._types.RemoveProcessor': 'ingest/_types/Processors.ts#L1358-L1372',
1776+
'ingest._types.RenameProcessor': 'ingest/_types/Processors.ts#L1374-L1390',
1777+
'ingest._types.RerouteProcessor': 'ingest/_types/Processors.ts#L1392-L1420',
1778+
'ingest._types.ScriptProcessor': 'ingest/_types/Processors.ts#L1422-L1442',
1779+
'ingest._types.SetProcessor': 'ingest/_types/Processors.ts#L1444-L1478',
1780+
'ingest._types.SetSecurityUserProcessor': 'ingest/_types/Processors.ts#L1480-L1489',
1781+
'ingest._types.ShapeType': 'ingest/_types/Processors.ts#L1491-L1494',
17811782
'ingest._types.SimulateDocumentResult': 'ingest/_types/Simulation.ts#L46-L50',
1782-
'ingest._types.SortProcessor': 'ingest/_types/Processors.ts#L1478-L1494',
1783-
'ingest._types.SplitProcessor': 'ingest/_types/Processors.ts#L1496-L1521',
1784-
'ingest._types.TerminateProcessor': 'ingest/_types/Processors.ts#L1523-L1523',
1785-
'ingest._types.TrimProcessor': 'ingest/_types/Processors.ts#L1525-L1541',
1786-
'ingest._types.UppercaseProcessor': 'ingest/_types/Processors.ts#L1543-L1559',
1787-
'ingest._types.UriPartsProcessor': 'ingest/_types/Processors.ts#L1579-L1605',
1788-
'ingest._types.UrlDecodeProcessor': 'ingest/_types/Processors.ts#L1561-L1577',
1783+
'ingest._types.SortProcessor': 'ingest/_types/Processors.ts#L1496-L1512',
1784+
'ingest._types.SplitProcessor': 'ingest/_types/Processors.ts#L1514-L1539',
1785+
'ingest._types.TerminateProcessor': 'ingest/_types/Processors.ts#L1541-L1541',
1786+
'ingest._types.TrimProcessor': 'ingest/_types/Processors.ts#L1543-L1559',
1787+
'ingest._types.UppercaseProcessor': 'ingest/_types/Processors.ts#L1561-L1577',
1788+
'ingest._types.UriPartsProcessor': 'ingest/_types/Processors.ts#L1597-L1623',
1789+
'ingest._types.UrlDecodeProcessor': 'ingest/_types/Processors.ts#L1579-L1595',
17891790
'ingest._types.UserAgentProcessor': 'ingest/_types/Processors.ts#L514-L545',
17901791
'ingest._types.UserAgentProperty': 'ingest/_types/Processors.ts#L547-L553',
17911792
'ingest._types.Web': 'ingest/_types/Database.ts#L61-L61',
@@ -3049,10 +3050,10 @@
30493050
if (hash.length > 1) {
30503051
hash = hash.substring(1);
30513052
}
3052-
window.location = "https://github.com/elastic/elasticsearch-specification/tree/c623a5d20613557e3e5d63a7a32eb36b58ac92ec/specification/" + (paths[hash] || "");
3053+
window.location = "https://github.com/elastic/elasticsearch-specification/tree/d42bde26cc35dfaa40757f48306a3559ab8d4ea8/specification/" + (paths[hash] || "");
30533054
</script>
30543055
</head>
30553056
<body>
3056-
Please see the <a href="https://github.com/elastic/elasticsearch-specification/tree/c623a5d20613557e3e5d63a7a32eb36b58ac92ec/specification/">Elasticsearch API specification</a>.
3057+
Please see the <a href="https://github.com/elastic/elasticsearch-specification/tree/d42bde26cc35dfaa40757f48306a3559ab8d4ea8/specification/">Elasticsearch API specification</a>.
30573058
</body>
30583059
</html>

java-client/src/main/java/co/elastic/clients/elasticsearch/ingest/InferenceProcessor.java

+110
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,9 @@
2828
import co.elastic.clients.util.ApiTypeHelper;
2929
import co.elastic.clients.util.ObjectBuilder;
3030
import jakarta.json.stream.JsonGenerator;
31+
import java.lang.Boolean;
3132
import java.lang.String;
33+
import java.util.List;
3234
import java.util.Map;
3335
import java.util.Objects;
3436
import java.util.function.Function;
@@ -69,6 +71,11 @@ public class InferenceProcessor extends ProcessorBase implements ProcessorVarian
6971
@Nullable
7072
private final InferenceConfig inferenceConfig;
7173

74+
private final List<InputConfig> inputOutput;
75+
76+
@Nullable
77+
private final Boolean ignoreMissing;
78+
7279
// ---------------------------------------------------------------------------------------------
7380

7481
private InferenceProcessor(Builder builder) {
@@ -78,6 +85,8 @@ private InferenceProcessor(Builder builder) {
7885
this.targetField = builder.targetField;
7986
this.fieldMap = ApiTypeHelper.unmodifiable(builder.fieldMap);
8087
this.inferenceConfig = builder.inferenceConfig;
88+
this.inputOutput = ApiTypeHelper.unmodifiable(builder.inputOutput);
89+
this.ignoreMissing = builder.ignoreMissing;
8190

8291
}
8392

@@ -134,6 +143,30 @@ public final InferenceConfig inferenceConfig() {
134143
return this.inferenceConfig;
135144
}
136145

146+
/**
147+
* Input fields for inference and output (destination) fields for the inference
148+
* results. This option is incompatible with the target_field and field_map
149+
* options.
150+
* <p>
151+
* API name: {@code input_output}
152+
*/
153+
public final List<InputConfig> inputOutput() {
154+
return this.inputOutput;
155+
}
156+
157+
/**
158+
* If true and any of the input fields defined in input_ouput are missing then
159+
* those missing fields are quietly ignored, otherwise a missing field causes a
160+
* failure. Only applies when using input_output configurations to explicitly
161+
* list the input fields.
162+
* <p>
163+
* API name: {@code ignore_missing}
164+
*/
165+
@Nullable
166+
public final Boolean ignoreMissing() {
167+
return this.ignoreMissing;
168+
}
169+
137170
protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) {
138171

139172
super.serializeInternal(generator, mapper);
@@ -161,6 +194,21 @@ protected void serializeInternal(JsonGenerator generator, JsonpMapper mapper) {
161194
this.inferenceConfig.serialize(generator, mapper);
162195

163196
}
197+
if (ApiTypeHelper.isDefined(this.inputOutput)) {
198+
generator.writeKey("input_output");
199+
generator.writeStartArray();
200+
for (InputConfig item0 : this.inputOutput) {
201+
item0.serialize(generator, mapper);
202+
203+
}
204+
generator.writeEnd();
205+
206+
}
207+
if (this.ignoreMissing != null) {
208+
generator.writeKey("ignore_missing");
209+
generator.write(this.ignoreMissing);
210+
211+
}
164212

165213
}
166214

@@ -184,6 +232,12 @@ public static class Builder extends ProcessorBase.AbstractBuilder<Builder>
184232
@Nullable
185233
private InferenceConfig inferenceConfig;
186234

235+
@Nullable
236+
private List<InputConfig> inputOutput;
237+
238+
@Nullable
239+
private Boolean ignoreMissing;
240+
187241
/**
188242
* Required - The ID or alias for the trained model, or the ID of the
189243
* deployment.
@@ -262,6 +316,60 @@ public final Builder inferenceConfig(InferenceConfigVariant value) {
262316
return this;
263317
}
264318

319+
/**
320+
* Input fields for inference and output (destination) fields for the inference
321+
* results. This option is incompatible with the target_field and field_map
322+
* options.
323+
* <p>
324+
* API name: {@code input_output}
325+
* <p>
326+
* Adds all elements of <code>list</code> to <code>inputOutput</code>.
327+
*/
328+
public final Builder inputOutput(List<InputConfig> list) {
329+
this.inputOutput = _listAddAll(this.inputOutput, list);
330+
return this;
331+
}
332+
333+
/**
334+
* Input fields for inference and output (destination) fields for the inference
335+
* results. This option is incompatible with the target_field and field_map
336+
* options.
337+
* <p>
338+
* API name: {@code input_output}
339+
* <p>
340+
* Adds one or more values to <code>inputOutput</code>.
341+
*/
342+
public final Builder inputOutput(InputConfig value, InputConfig... values) {
343+
this.inputOutput = _listAdd(this.inputOutput, value, values);
344+
return this;
345+
}
346+
347+
/**
348+
* Input fields for inference and output (destination) fields for the inference
349+
* results. This option is incompatible with the target_field and field_map
350+
* options.
351+
* <p>
352+
* API name: {@code input_output}
353+
* <p>
354+
* Adds a value to <code>inputOutput</code> using a builder lambda.
355+
*/
356+
public final Builder inputOutput(Function<InputConfig.Builder, ObjectBuilder<InputConfig>> fn) {
357+
return inputOutput(fn.apply(new InputConfig.Builder()).build());
358+
}
359+
360+
/**
361+
* If true and any of the input fields defined in input_ouput are missing then
362+
* those missing fields are quietly ignored, otherwise a missing field causes a
363+
* failure. Only applies when using input_output configurations to explicitly
364+
* list the input fields.
365+
* <p>
366+
* API name: {@code ignore_missing}
367+
*/
368+
public final Builder ignoreMissing(@Nullable Boolean value) {
369+
this.ignoreMissing = value;
370+
return this;
371+
}
372+
265373
@Override
266374
protected Builder self() {
267375
return this;
@@ -294,6 +402,8 @@ protected static void setupInferenceProcessorDeserializer(ObjectDeserializer<Inf
294402
op.add(Builder::targetField, JsonpDeserializer.stringDeserializer(), "target_field");
295403
op.add(Builder::fieldMap, JsonpDeserializer.stringMapDeserializer(JsonData._DESERIALIZER), "field_map");
296404
op.add(Builder::inferenceConfig, InferenceConfig._DESERIALIZER, "inference_config");
405+
op.add(Builder::inputOutput, JsonpDeserializer.arrayDeserializer(InputConfig._DESERIALIZER), "input_output");
406+
op.add(Builder::ignoreMissing, JsonpDeserializer.booleanDeserializer(), "ignore_missing");
297407

298408
}
299409

0 commit comments

Comments
 (0)