You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The ES|QL helper can now return results as an Apache Arrow `Table` or `RecordBatchReader`, which enables high-performance calculations on ES|QL results, even if the response data is larger than the system's available memory. See <<esql-helper>> for more information.
@@ -208,14 +208,14 @@ Following you can find all the supported authentication strategies.
208
208
[[auth-apikey]]
209
209
==== ApiKey authentication
210
210
211
-
You can use the
212
-
{ref-7x}/security-api-create-api-key.html[ApiKey]
213
-
authentication by passing the `apiKey` parameter via the `auth` option. The
214
-
`apiKey` parameter can be either a base64 encoded string or an object with the
215
-
values that you can obtain from the
211
+
You can use the
212
+
{ref-7x}/security-api-create-api-key.html[ApiKey]
213
+
authentication by passing the `apiKey` parameter via the `auth` option. The
214
+
`apiKey` parameter can be either a base64 encoded string or an object with the
215
+
values that you can obtain from the
216
216
{ref-7x}/security-api-create-api-key.html[create api key endpoint].
217
217
218
-
NOTE: If you provide both basic authentication credentials and the ApiKey
218
+
NOTE: If you provide both basic authentication credentials and the ApiKey
219
219
configuration, the ApiKey takes precedence.
220
220
221
221
[source,js]
@@ -268,10 +268,10 @@ const client = new Client({
268
268
[[auth-basic]]
269
269
==== Basic authentication
270
270
271
-
You can provide your credentials by passing the `username` and `password`
271
+
You can provide your credentials by passing the `username` and `password`
272
272
parameters via the `auth` option.
273
273
274
-
NOTE: If you provide both basic authentication credentials and the Api Key
274
+
NOTE: If you provide both basic authentication credentials and the Api Key
275
275
configuration, the Api Key will take precedence.
276
276
277
277
[source,js]
@@ -342,14 +342,14 @@ const result = await client.search({
342
342
}, { meta: true })
343
343
----
344
344
345
-
In this case, the result will be:
345
+
In this case, the result will be:
346
346
[source,ts]
347
347
----
348
348
{
349
349
body: object | boolean
350
350
statusCode: number
351
351
headers: object
352
-
warnings: [string],
352
+
warnings: string[],
353
353
meta: object
354
354
}
355
355
----
@@ -361,7 +361,7 @@ NOTE: The body is a boolean value when you use `HEAD` APIs.
361
361
362
362
If needed, you can abort a running request by using the `AbortController` standard.
363
363
364
-
CAUTION: If you abort a request, the request will fail with a
364
+
CAUTION: If you abort a request, the request will fail with a
365
365
`RequestAbortedError`.
366
366
367
367
@@ -410,19 +410,23 @@ The supported request specific options are:
410
410
[cols=2*]
411
411
|===
412
412
|`ignore`
413
-
|`[number]` - HTTP status codes which should not be considered errors for this request. +
413
+
|`number[]` - HTTP status codes which should not be considered errors for this request. +
414
414
_Default:_ `null`
415
415
416
416
|`requestTimeout`
417
-
|`number` - Max request timeout for the request in milliseconds, it overrides the client default. +
417
+
|`number | string` - Max request timeout for the request in milliseconds, it overrides the client default. +
418
418
_Default:_ `30000`
419
419
420
+
|`retryOnTimeout`
421
+
|`boolean` - Retry requests that have timed out.
422
+
_Default:_ `false`
423
+
420
424
|`maxRetries`
421
425
|`number` - Max number of retries for the request, it overrides the client default. +
422
426
_Default:_ `3`
423
427
424
428
|`compression`
425
-
|`string, boolean` - Enables body compression for the request. +
429
+
|`string | boolean` - Enables body compression for the request. +
426
430
_Options:_ `false`, `'gzip'` +
427
431
_Default:_ `false`
428
432
@@ -446,6 +450,10 @@ _Default:_ `null`
446
450
|`any` - Custom object per request. _(you can use it to pass data to the clients events)_ +
447
451
_Default:_ `null`
448
452
453
+
|`opaqueId`
454
+
|`string` - Set the `X-Opaque-Id` HTTP header. See {ref}/api-conventions.html#x-opaque-id
455
+
_Default:_ `null`
456
+
449
457
|`maxResponseSize`
450
458
|`number` - When configured, it verifies that the uncompressed response size is lower than the configured number, if it's higher it will abort the request. It cannot be higher than buffer.constants.MAX_STRING_LENTGH +
451
459
_Default:_ `null`
@@ -458,6 +466,17 @@ _Default:_ `null`
458
466
|`AbortSignal` - The AbortSignal instance to allow request abortion. +
459
467
_Default:_ `null`
460
468
469
+
|`meta`
470
+
|`boolean` - Rather than returning the body, return an object containing `body`, `statusCode`, `headers` and `meta` keys +
471
+
_Default_: `false`
472
+
473
+
|`redaction`
474
+
|`object` - Options for redacting potentially sensitive data from error metadata. See <<redaction>>.
475
+
476
+
|`retryBackoff`
477
+
|`(min: number, max: number, attempt: number) => number;` - A function that calculates how long to sleep, in seconds, before the next request retry +
478
+
_Default:_ A built-in function that uses exponential backoff with jitter.
479
+
461
480
|===
462
481
463
482
[discrete]
@@ -537,8 +556,8 @@ Resources used to assess these recommendations:
537
556
538
557
~Added~ ~in~ ~`v7.10.0`~
539
558
540
-
If you need to pass through an http(s) proxy for connecting to {es}, the client
541
-
out of the box offers a handy configuration for helping you with it. Under the
559
+
If you need to pass through an http(s) proxy for connecting to {es}, the client
560
+
out of the box offers a handy configuration for helping you with it. Under the
542
561
hood, it uses the https://github.com/delvedor/hpagent[`hpagent`] module.
543
562
544
563
IMPORTANT: In versions 8.0+ of the client, the default `Connection` type is set to `UndiciConnection`, which does not support proxy configurations.
@@ -715,5 +734,5 @@ This pre-flight product check allows the client to establish the version of Elas
715
734
that it is communicating with. The product check requires one additional HTTP request to
716
735
be sent to the server as part of the request pipeline before the main API call is sent.
717
736
In most cases, this will succeed during the very first API call that the client sends.
718
-
Once the product check completes, no further product check HTTP requests are sent for
737
+
Once the product check completes, no further product check HTTP requests are sent for
0 commit comments