Commit graph

75439 commits

Author SHA1 Message Date
David Turner
09df993931 AwaitsFix for #106618 2024-03-21 16:39:49 +00:00
István Zoltán Szabó
17ed5bc2a4
[DOCS] Amends important note on delayed data detection. (#106610) (#106614) 2024-03-21 12:04:33 -04:00
István Zoltán Szabó
d7b3accfa0
[DOCS] Adjusts PUT inference API docs examples (#106604) (#106606)
Co-authored-by: David Kyle <david.kyle@elastic.co>
2024-03-21 10:17:58 -04:00
István Zoltán Szabó
8b50e93124
[DOCS] Adds note to inference tutorial about similarity (#106567) (#106605) 2024-03-21 09:55:11 -04:00
István Zoltán Szabó
893e85b3e2
[DOCS] Adds disclaimer to semantic search tutorials (#106590) (#106594) 2024-03-21 06:54:10 -04:00
Przemysław Witek
c212abddeb
[Transform] Fix _reset API when called with force=true on a failed transform (#106574) (#106589) 2024-03-21 06:42:13 -04:00
Mark Vieira
d1c98f39fd
Validate that test cluster BWC nodes use the default distribution (#106559) (#106565)
We have instances where BWC tests configure old ES version nodes with
the integTest distribution. This isn't a valid configuration, and while
we in reality resolve the default distribution artifact, we have other
configuration logic that behaves differently based on whether the
integTest distro was _requested_. Specifically, what to set ES_JAVA_HOME
to. This bug resulted in us attempting to run old nodes using the
current bundled JDK version, which may be incompatible with that older
version of Elasticsearch.

Closes #104858
2024-03-20 12:55:47 -04:00
Ignacio Vera
4bf910c6e8
Use LogDocMergePolicy in GeoPointScriptFieldDistanceFeatureQueryTests#testMatches (#106557) (#106562) 2024-03-20 12:24:13 -04:00
David Turner
80634b494f
Release TranslogSnapshot buffer after iteration (#106398) (#106556)
Closes #106390
2024-03-20 11:41:54 -04:00
David Turner
d281df79bd
Integrate threadpool scheduling with AbstractRunnable (#106542) (#106548)
Today `ThreadPool#scheduleWithFixedDelay` does not interact as expected
with `AbstractRunnable`: if the task fails or is rejected then this
isn't passed back to the relevant callback, and the task cannot specify
that it should be force-executed. This commit fixes that.
2024-03-20 10:50:02 -04:00
David Turner
21f1123113
Force execution of SearchService.Reaper (#106544) (#106547)
If the search threadpool fills up then we may reject execution of
`SearchService.Reaper` which means it stops retrying. We must instead
force its execution so that it keeps on going.

With #106542, closes #106543
2024-03-20 10:31:05 -04:00
István Zoltán Szabó
6d8da67bf1
[DOCS] Changes Cohere inference examples in tutorial and API docs (#106524) (#106551) 2024-03-20 10:29:58 -04:00
Aurélien FOUCRET
e29365583d
Ensure ILM policy is installed before starting the tests. (#106523) (#106545) 2024-03-20 09:19:11 -04:00
Navarone Feekery
d40ff36a20
[Connectors API] Add missing _api_key_id docs (#106469) (#106539) 2024-03-20 07:28:09 -04:00
Ioana Tagirta
a892165bd7
Add links to text_expansion in ELSER tutorial (#106490) (#106530)
* Add links to text_expansion in ELSER tutorial

* Apply suggestions from code review



---------

Co-authored-by: Liam Thompson <32779855+leemthompo@users.noreply.github.com>
2024-03-20 05:24:49 -04:00
Yang Wang
50c71bcfdb
[Test] Ranged read should read non-empty content (#106000) (#106525)
Empty read is
[short-circuited](e8039b9ecb/modules/repository-s3/src/main/java/org/elasticsearch/repositories/s3/S3BlobContainer.java (L115-L116))
without going to the blob store. In order to test s3 blob store, ranged
read should read at least one byte. This PR ensures that.

Resolves: #105958
2024-03-20 04:56:14 -04:00
Nhat Nguyen
76aee0b313
Fix testCancelRequestWhenFailingFetchingPages (#106447) (#106515)
If we proceed without waiting for pages, we might cancel the main 
request before starting the data-node request. As a result, the exchange
sinks on data-nodes won't be removed until the inactive_timeout elapses,
which is longer than the assertBusy timeout.

Closes #106443
2024-03-19 18:54:03 -04:00
Mark Vieira
4aaf00c212
Update bundled JDK to Java 22 (#106482) (#106508)
# Conflicts:
#	build-tools-internal/src/main/java/org/elasticsearch/gradle/internal/toolchain/OracleOpenJdkToolchainResolver.java
2024-03-19 16:25:35 -04:00
Liam Thompson
c7b41ac3ea
[8.13] (DOC+) Version API page for ES API Base URL (#105845) (#106459)
* (DOC+) Version API page for ES API Base URL (#105845)

* (DOC+) Version API page for ES API Base URL

Co-authored-by: Liam Thompson <32779855+leemthompo@users.noreply.github.com>
(cherry picked from commit 157ce539aa)

* Fix URL syntax, copy nit

---------

Co-authored-by: Stef Nestor <26751266+stefnestor@users.noreply.github.com>
2024-03-19 05:58:04 -04:00
Nhat Nguyen
9a8864c21e
AwaitsFix #106443 (#106453) 2024-03-18 21:59:24 -04:00
Nhat Nguyen
aa2e022b31
Resume driver when failing to fetch pages (#106392) (#106436)
I investigated a heap attack test failure and found that an ESQL request
was stuck. This occurred in the following:

1. The ExchangeSource on the coordinator was blocked on reading because
there were no available pages.

2. Meanwhile, the ExchangeSink on the data node had pages ready for
fetching.

3. When an exchange request tried to fetch pages, it failed due to a
CircuitBreakingException. Despite the failure, no cancellation was
triggered because the status of the ExchangeSource on the coordinator
remained unchanged.  To fix this issue, this PR introduces two changes:

Resumes the ExchangeSourceOperator and Driver on the coordinator,
eventually allowing the coordinator to trigger cancellation of the
request when failing to fetch pages.

Ensures that an exchange sink on the data nodes fails when a data node
request is cancelled. This callback was inadvertently omitted when
introducing the node-level reduction in Run empty reduction node level
on data nodes #106204.

I plan to spend some time to harden the exchange and compute service.

Closes #106262
2024-03-18 12:04:22 -07:00
Liam Thompson
35d6d1ebf4
[DOCS] Add contextual info about connectors to API docs (#106420) (#106421)
* [DOCS] Add contextual info about connectors to API docs

* Grammar nit
2024-03-18 11:31:18 -04:00
Ignacio Vera
1ce9825bf0
Fix potential BigArray leak in InternalAggregation#getReducer (#106406) (#106412) 2024-03-18 09:30:24 -04:00
Craig Taverner
5dd26f762d
Make new spatial sort tests less flaky (#106401) (#106405)
The tests that assert sorting on spatial types causes consistent error messages, also were flaky for the non-error message cases under rare circumstances where the results were returned in different order. We now sort those on a sortable field for deterministic behaviour.
2024-03-18 07:47:33 -04:00
David Turner
887164dbcc Clarify docs about the flood-stage index block (#106391)
The docs here are a little inaccurate, and link to several individual
settings (incorrectly in some cases) in a paragraph that's pretty hard
to read. This commit fixes the inaccuracies and replaces the links to
individual settings with one to all the docs about the disk-based shard
allocator.
2024-03-18 08:07:54 +00:00
Athena Brown
97d4a86427
Adjust interception of requests for specific shard IDs (#101656) (#106376)
Some index requests target shard IDs specifically, which may not match the indices that the request targets as given by `IndicesRequest#indices()`, which requires a different interception strategy in order to make sure those requests are handled correctly in all cases and that any malformed messages are caught early to aid in troubleshooting.

This PR adds and interface allowing requests to report the shard IDs they target as well as the index names, and adjusts the interception of those requests as appropriate to handle those shard IDs in the cases where they are relevant.
2024-03-14 19:52:33 -04:00
Craig Taverner
45576fc0b4
ESQL: Fix error on sorting unsortable geo_point and cartesian_point (#106351) (#106379)
* Fix error on sorting unsortable geo_point and cartesian_point

Without a LIMIT the correct error worked, but with LIMIT it did not. This fix mimics the same error with LIMIT and adds tests for all three scenarios:
* Without limit
* With Limit
* From row with limit

* Update docs/changelog/106351.yaml

* Add tests for geo_shape and cartesian_shape also

* Updated changelog

* Separate point and shape error messages

* Move error to later so we get it only if geo field is actually used in sort.

* Implemented planner check in Verifier instead

This is a much better solution.

* Revert previous solution

* Also check non-field attributes so the same error is provided for ROW

* Changed "can't" to "cannot"

* Add unit tests for verifier error

* Added sort limitations to documentation

* Added unit tests for spatial fields in VerifierTests

* Don't run the new yaml tests on older versions

These tests mostly test the validation errors which were changed only in 8.14.0, so should not be tested in earlier versions.

* Simplify check based on code review, skip duplicate forEachDown
2024-03-14 19:08:05 -04:00
Brian Seeders
2a83bab025
[ci] Refactor BWC templating in Buildkite pipelines to handle more scenarios (#106084) (#106096)
(cherry picked from commit 6f8280c12a)
2024-03-14 16:45:40 -04:00
Liam Thompson
24db6c46a8
[DOCS][ESQL] Add link to getting started notebook (#106345) (#106369) 2024-03-14 12:54:55 -04:00
Liam Thompson
0b9671d8ca
[DOCS] Remove CCS limitation for 8.13+ (#106343) (#106368) 2024-03-14 12:10:34 -04:00
Lisa Cawley
fd01b8a12e
[DOCS] Update transform health rule details (#105719) (#106242) 2024-03-14 07:57:11 -07:00
Kathleen DeRusso
b835827311
Fix Search Applications bug where deleting an alias before deleting an application intermittently caused errors (#106329) (#106354)
* Update delete object to never fail if alias does not exist

* Update docs/changelog/106329.yaml

* Update changelog

* Fix area in changelog
2024-03-14 09:18:16 -04:00
Matteo Piergiovanni
56469e9507
[8.13] Field caps performance pt2 (#105941) (#106341) 2024-03-14 11:39:06 +01:00
Mark Vieira
9622dc0b23
Remove redundant BWC testing
(cherry picked from commit 6d040d9bea)
2024-03-13 18:06:21 -07:00
Lloyd
44e8f72b47
[IdP plugin] Fix exception handling (#106231) (#106336)
* Add regression tests that test ACS and entity id mismatch, causing
  us to go into the initCause branch

* Fix up exception creation: initCause it not
  allowed because ElasticsearchException
  initialises the cause to `null` already if
  it isn't passed as a contructor param.

Signed-off-by: lloydmeta <lloydmeta@gmail.com>
2024-03-13 20:25:30 -04:00
Youhei Sakurai
5198e7f041
Handling exceptions on watcher reload (#105442) (#106210) 2024-03-13 15:46:24 -05:00
Jonathan Buttner
74dfe58f11
Allowing byte and int8 (#106299) (#106326)
(cherry picked from commit de33a57f55)

# Conflicts:
#	x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/cohere/CohereService.java
#	x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/cohere/CohereServiceSettings.java
#	x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/openai/OpenAiService.java
#	x-pack/plugin/inference/src/main/java/org/elasticsearch/xpack/inference/services/openai/embeddings/OpenAiEmbeddingsServiceSettings.java
#	x-pack/plugin/inference/src/test/java/org/elasticsearch/xpack/inference/services/cohere/CohereServiceSettingsTests.java
#	x-pack/plugin/inference/src/test/java/org/elasticsearch/xpack/inference/services/cohere/embeddings/CohereEmbeddingsServiceSettingsTests.java
#	x-pack/plugin/inference/src/test/java/org/elasticsearch/xpack/inference/services/openai/embeddings/OpenAiEmbeddingsServiceSettingsTests.java

Co-authored-by: Elastic Machine <elasticmachine@users.noreply.github.com>
2024-03-13 16:05:57 -04:00
Craig Taverner
88ff3c6613
Fix #106126 in 8.13 (#106318) 2024-03-13 20:03:21 +01:00
Martijn van Groningen
0d1e7a4a0e
Small time series agg improvement (#106288) (#106307)
After tsid hashing was introduced (#98023), the time series aggregator generates the tsid (from all dimension fields) instead of using the value from the _tsid field directly. This generation of the tsid happens for every time serie, parent bucket and segment combination.

This changes alters that by only generating the tsid once per time serie and segment. This is done by just locally recording the current tsid.
2024-03-13 13:02:58 -04:00
Kostas Krikellas
be29f7fe3b
[TEST] Increase timeout for rollover to exceed look_ahead_time (#106290) (#106291)
`look_ahead_time` is set to 1 minute, the `assertBusy` loop needs to
wait for longer than that to get a readonly backing index. 

Note that this is only relevant when the `UpdateTimeSeriesRangeService`
kicks in to bump the end time of the head index. This is rare (it runs
every 10 minutes) but can happen.

Fixes #101428
2024-03-13 11:20:25 -04:00
Rene Groeschke
aefa784360
Cleanup SamlAuthenticationIT (#106227) (#106287)
Remove comments about awaitsFix
2024-03-13 09:32:55 -04:00
Rene Groeschke
63e4917775
Add Saml test connection timeout debugging output (#104801) (#106226)
Add additional logging to idp test fixture container

(cherry picked from commit 46beceb180)
2024-03-13 13:07:11 +01:00
Kostas Krikellas
3d7122996b
backport pr-106225 (#106278) 2024-03-13 04:27:45 -04:00
Aurélien FOUCRET
86fd9b6a31
Fix typo in the LTR guide. (#106276) (#106281) 2024-03-13 04:25:59 -04:00
Kathleen DeRusso
85ed7efb57
Fix typo in text_expansion example (#106265) (#106267) 2024-03-12 15:40:23 -04:00
David Kyle
f30f6adf98
[ML] Make task settings optional when creating Cohere embedding models (#106241) (#106258)
# Conflicts:
#	x-pack/plugin/inference/src/test/java/org/elasticsearch/xpack/inference/services/cohere/CohereServiceTests.java
2024-03-12 14:33:44 -04:00
István Zoltán Szabó
0029b2e472
[DOCS] Changes element_type in index mapping for the infrence tutorial. (#106233) (#106237) 2024-03-12 10:06:08 -04:00
Nicole Albee
ca8e9afe52
Clarify filters can be used while creating a normalizer. (#103826) (#106235) 2024-03-12 09:43:20 -04:00
David Turner
e2c9767c93
Expand docs on number value conventions (#106198) (#106201)
Today we do not say explicitly that `integer` response fields are really
arbitrarily large JSON integers and may not fit into a Java `int`. This
commit expands the docs to add this information.
2024-03-11 15:55:47 -04:00
Aurélien FOUCRET
11de303556
First version of the LTR guide. (#105956) (#106195) 2024-03-11 12:47:50 -04:00