Commit graph

87430 commits

Author SHA1 Message Date
Craig Taverner
e6347b8ab0
[DOCS] Update ES|QL generated docs to consistently use the applies_to metadata (#128576)
- Add PREVIEW annotations to all preview functions
- Update docs generation logic to use annotations instead of preview boolean
* Changed stack: ga 9.1 to stack: coming in multiple places
  - Match.java: Updated the options parameter description
  - MultiMatch.java: Updated the options parameter description
  - ToLower.java: Reformatted parameter description and updated version annotation
  - ToUpper.java: Removed the appliesTo annotation entirely and reformatted parameter description

- updated applies_to annotations to specify both preview 9.0.0 and ga 9.1.0 lifecycle stages
- added version-specific documentation examples with applies_to markers for ga 9.1.0 features
- enhanced to_lower and to_upper functions to indicate support for multi-valued expressions in ga 9.1.0
- added version guards around function parameters and descriptions using applies_to syntax
- updated function parameter descriptions to indicate ga 9.1.0 availability for named parameters
- use detailedDescription + and fix match_phrase applies_to syntax
- strip inline applies_to from kibana docs
- update roundto, matchphrase lifecycles
-  fix match named params info
- various spatial functions are preview
- unsigned long is preview
- update qstr
- Update TO_LOWER/TO_UPPER parameter descriptions for clarity
- hide spatial functions per https://github.com/elastic/elasticsearch/pull/129839
- added `stack: ga 9.1.0` blocks to match_phrase.md and qstr.md examples
- simplified term.md version from `preview 9.0.0` to just `preview`
- added `applies_to = "stack: ga 9.1.0"` to matchphrase and querystring java annotations
- removed version `9.0.0` from term function annotation
- deleted unused `makeCallout()` and `appendLifeCycleAndVersion()` methods


Co-authored-by: elasticsearchmachine <infra-root+elasticsearchmachine@elastic.co>
Co-authored-by: Liam Thompson <leemthompo@gmail.com>
Co-authored-by: Liam Thompson <32779855+leemthompo@users.noreply.github.com>
Co-authored-by: Nik Everett <nik9000@gmail.com>
2025-06-23 20:07:41 +02:00
Lola
ded666ec66
[Cloud Security Posture] fix ilm deletion step error permissions (#128634)
* fix ilm deletion step policy

* [CI] Auto commit changes from spotless

---------

Co-authored-by: elasticsearchmachine <infra-root+elasticsearchmachine@elastic.co>
2025-06-24 02:56:13 +10:00
Ignacio Vera
ffea6ca2bf
Introduce an int4 off-heap vector scorer (#129824)
* Introduce an int4 off-heap vector scorer

* iter

* Update server/src/main/java/org/elasticsearch/index/codec/vectors/DefaultIVFVectorsReader.java

Co-authored-by: Benjamin Trent <ben.w.trent@gmail.com>

---------

Co-authored-by: Benjamin Trent <ben.w.trent@gmail.com>
2025-06-23 18:44:12 +02:00
Charlotte Hoblik
321a39738a
[DOCS]: Add connectors release notes for 9.0.3 (#129861)
* Add connectors release notes for 9.0.3

* Add release note
2025-06-23 17:16:59 +01:00
Mary Gouseti
d859366d4b
Add an error margin when comparing floats. (#129721)
We add a margin of error when comparing floats to the DynamicFieldMatcher to account for a small loss of accuracy when loading fields from synthetic source.
2025-06-23 18:46:46 +03:00
David Kyle
816caf70fc
[ML] Check for model deployment in inference endpoints before stopping (#129325) 2025-06-23 16:39:51 +01:00
Mike Pellegrini
636da86ccb
Simplified RRF Retriever (#129659) 2025-06-23 11:35:28 -04:00
Niels Bauman
f430a6c28c
Fix index stats field data YAML test (#129816)
Occasional shard allocation issues were causing the YAML tests to fail
because the shard that had the document in it would be unavailable.

Fixes #96711
2025-06-24 01:32:27 +10:00
Tim Brooks
53dae7a3a2
Dispatch ingest work to coordination thread pool (#129820)
The vast majority of ingest pipelines are light CPU
operations. We don't want these to be put behind IO work on the write
executor. Instead, execute these on the coordination pool.
2025-06-23 09:31:36 -06:00
Niels Bauman
bae6e3c66d
Fix data stream stats YAML test (#129813)
Occasional shard allocation issues were causing the YAML tests to fail
because the shard that had the document with the max timestamp in it
would be unavailable.

Fixes #118217
2025-06-24 01:22:48 +10:00
Alexander Spies
efb1397fe9
ESQL: Hide spatial grid functions behind SNAPSHOT (#129839)
#125143 added 9 spatial grid functions and released them into Serverless. We think this is not the best long-term approach and the functions in #129581 are likely better.

As a first step, rmove the spatial grid functions added in #125143 from release builds so they don't get released into 8.19/9.1.

---------

Co-authored-by: Craig Taverner <craig@amanzi.com>
2025-06-23 17:16:30 +02:00
Panagiotis Bailis
7d4bbcc4bb
Fix for RescoreKnnVectorQueryIT to ensure that BBQ_IVF format is enabled (#129830) 2025-06-23 17:57:31 +03:00
Jonathan Buttner
c7a5c5923c
[ML] Removing Custom Service Feature Flag (#129780)
* Removing feature flag

* Removing missed references
2025-06-23 10:44:59 -04:00
Keith Massey
2f3b2b39c5
Using the STREAMS_LOGS_SUPPORT_8_19 transport version (#129796)
* Using the STREAMS_LOGS_SUPPORT_8_19 transport version

* Update StreamsMetadata.java

Returning null from getMinimalSupportedVersion

* Return minimal supported version as 8.19 for metadata object to fix test fail

---------

Co-authored-by: Luke Whiting <luke.whiting@elastic.co>
2025-06-24 00:20:20 +10:00
Brendan Jugan
cef717c087
add default inference endpoint for Elastic Inference Service rerank (#129681)
* add Elastic Inference Service rerank default inference endpoint

* [CI] Auto commit changes from spotless

* fix integ tests

* update mock Elastic Inference Service authorization response

* fix rerank service test

---------

Co-authored-by: elasticsearchmachine <infra-root+elasticsearchmachine@elastic.co>
2025-06-23 09:48:50 -04:00
Rene Groeschke
648c5ad15f
[Build] Make DependenciesInfoPlugin configuration cache compatible (#129791)
We can now run projects check tasks and :distribution:generateDependenciesReport with 
configuration cache enabled (--configuration-cache)
2025-06-23 15:45:54 +02:00
Mike Pellegrini
0c89548681
Mute the "rrf with pinned retriever as a sub-retriever" test (#129846) 2025-06-23 09:43:42 -04:00
Jan Kuipers
a3dac7434b
TransportVersion for backporting ES|QL sample (#129831) 2025-06-23 15:28:14 +02:00
elasticsearchmachine
e031b3e8d3 Mute org.elasticsearch.index.store.FsDirectoryFactoryTests testPreload #129852 2025-06-23 23:26:35 +10:00
Ignacio Vera
72b488cfa9
[IVF] Improve the format of the tmp file written during merging (#129828)
This commit separe vector and docIds on the tmp file.
2025-06-23 14:44:00 +02:00
István Zoltán Szabó
b1741e8a96
DOCS] Adds update cross cluster API key API examples (#129843)
* DOCS] Adds update cross cluster API k
ey API examples.

* Fixes markup.

* Update docs/reference/elasticsearch/rest-apis/update-cc-api-key-examples.md

Co-authored-by: Liam Thompson <32779855+leemthompo@users.noreply.github.com>

* [DOCS] Subheadings.

---------

Co-authored-by: Liam Thompson <32779855+leemthompo@users.noreply.github.com>
2025-06-23 14:43:31 +02:00
Ioana Tagirta
11ca4f688a
ES|QL: Add number of max branches for FORK (#129834) 2025-06-23 13:48:06 +02:00
Lorenzo Dematté
81bb0b5987
Remove es.serverless_transport=true (#129760)
Now that #128589, we do not need to use the serverless FF to skip the check.
This PR removes it.

Relates to https://elasticco.atlassian.net/browse/ES-12004
2025-06-23 20:49:26 +10:00
Luigi Dell'Aquila
085ef5c7fd
Fix generative tests (#129833) 2025-06-23 20:14:46 +10:00
Alexander Spies
809dab1c3a
ESQL: Pushdown Lookup Join past Project (#129503)
Add a new logical plan optimization:

When there is a Project (KEEP/DROP/RENAME/renaming EVALs) in a LOOKUP JOIN's left child (the "main" side), perform the Project after the LOOKUP JOIN. This prevents premature field extractions when the lookup join happens on data nodes.
2025-06-23 12:05:45 +02:00
Slobodan Adamović
2502a363de
[UIAM] Cloud API key authentication metadata and validations (#129227)
A followup to #128440, which introduces a new `managed_by` field (`<1>`) that will be returned in the response of the Authenticate API.


Besides `managed_by` field, it also captures additional `internal` field (`<2>`) for cloud API key authentication and exposes it as part of the `api_key` fields.

```json
{
  "username": "omSAd5YBK3gZiBcD-GvX", 
  "roles": [ "viewer" ],
  "metadata": {
    ...
  },
  "enabled": true,
  "authentication_realm": {
    "name": "_cloud_api_key",
    "type": "_cloud_api_key"
  },
  "lookup_realm": {
    "name": "_cloud_api_key",
    "type": "_cloud_api_key"
  },
  "authentication_type": "api_key",
  "api_key": { 
    "id": "omSAd5YBK3gZiBcD-GvX",
    "name": "my cloud API key",
    "managed_by": "cloud", <1>
    "internal": false <2>
  }
}

```


- Additionally it implements the `Authentication#canAccessResourcesOf` for the cloud API keys. Ownership check allows access only to the same cloud API key.

- And lastly, adds a consistency check for cloud API keys in `Authentication#checkConsistencyForApiKeyAuthenticationType`.
2025-06-23 11:45:41 +02:00
Chris Hegarty
f1ea88e1e8
Port IndexVersions.UPGRADE_TO_LUCENE_9_12_2 to main (#129832)
This commit ports the IndexVersions.UPGRADE_TO_LUCENE_9_12_2 constant to the main branch.

This is required after the update of Lucene 9.12.2 in the 8.19 branch, see #129555.
2025-06-23 09:32:37 +01:00
Ioana Tagirta
9cc386f377
Add FORK generator back (#129790) 2025-06-23 10:06:29 +02:00
Jan Calanog
cc405dc83c
docs-builder: add pull-requests: write permission to docs-build workflow (#129779)
Co-authored-by: shainaraskas <58563081+shainaraskas@users.noreply.github.com>
2025-06-23 10:01:05 +02:00
Luigi Dell'Aquila
a79bbffb0b
ES|QL: enable EXPLAIN (snapshot only) (#129526) 2025-06-23 09:55:45 +02:00
Rene Groeschke
f1b2c8dd8e
Split up bc and pr upgrade tests (#129756)
Splits up bc and pr upgrade tests as they tend to be a bottle neck in intake and pr builds nowadays.
2025-06-23 09:17:54 +02:00
Sam Xiao
e3838a4b9c
Make GeoIp downloader multi-project aware (#128282)
This change makes the GeoIp persistent task executor/downloader multi-project aware. 
- the database downloader persistent task will be at the project level, meaning there will be a downloader instance per project
- persistent task id is prefixed with project id, namely `<project-id>/geoip-downloader` for cluster in MP mode
2025-06-23 15:07:40 +08:00
Martijn van Groningen
41f69810df
Force niofs for fdt tmp file read access when flushing stored fields (#129538)
Due to the way how stored fields get flushed when index sorting is active, it is possible that we encounter significant page cache faults when memory is scarce. In order to mitigate some of the slowness around this, we're planning to no longer mmap the fdt temp file. Initially behind a feature flag, to check for unforeseen side effects.

Typically using always mmap directory is better compared to noifs directory given there is a sufficient memory available to the OS for filesystem caching. However when that isn't the case, then indexing performance can vary a lot (often very slow). This is more true for files tmp files that stored fields create during flushing. These files exist for only a brief moment to sort stored fields in the order of the configured index sorting and are then removed. If these tmp files are mmapped there is risk to trash file system cache.

This change only avoids using mmap for the fdt tmp file. This the file that actually contains the data and can large compared to other files that get flushed. The fdm (metadata) and fdi (stored field index) remain being mmapped.
2025-06-23 07:46:00 +02:00
elasticsearchmachine
13365dd14f Mute org.elasticsearch.index.engine.ThreadPoolMergeExecutorServiceDiskSpaceTests testAbortingOrRunningMergeTaskHoldsUpBudget #129823 2025-06-23 15:20:20 +10:00
Ignacio Vera
5bec44ad58
Reduce data amplification in IVFVectorsWriter (#129698)
With this change we will create first the tmp file and the posting list and once the file is deleted we will 
merge the vectors on the vec file. Therefore we only have two copies of the vector at the same time.
2025-06-23 07:13:22 +02:00
elasticsearchmachine
3c1137688e Mute org.elasticsearch.xpack.esql.qa.single_node.GenerativeIT test #129819 2025-06-23 09:04:21 +10:00
elasticsearchmachine
73146ac304 Mute org.elasticsearch.qa.verify_version_constants.VerifyVersionConstantsIT testLuceneVersionConstant #125638 2025-06-23 08:28:39 +10:00
elasticsearchmachine
c2ebe1b535 Mute org.elasticsearch.search.query.RescoreKnnVectorQueryIT testKnnRetriever #129818 2025-06-23 07:34:58 +10:00
Chris Hegarty
1255a64832
Upgrade to Lucene 10.2.2 (#129546)
This commit upgrades to Upgrade to Lucene 10.2.2.

With the release of 10.2.2, we no longer need to workaround the Lucene bug mentioned in 128671.
2025-06-22 13:37:22 +01:00
elasticsearchmachine
6a1a862aea Mute org.elasticsearch.search.query.RescoreKnnVectorQueryIT testKnnQueryRescore #129809 2025-06-21 23:30:20 +10:00
Simon Chase
cb451dac0b
datafeed: check remote_cluster_client before cluster aliases in start (#129601)
TransportStartDatafeedAction previously tried to validate remote index cluster
names in datafeed jobs, before checking if the local cluster had
remote_cluster_client role. Because this role enables retrieval of the remote
cluster names, the validation step would always fail with a no-such-cluster
exception. This was confusing. This change moves the remote_cluster_client check
ahead of cluster name validation, and adds a test.

Closes ES-11841
Closes #121149
2025-06-20 16:25:35 -07:00
Nik Everett
0b35acf861
ESQL: Fix misspelling in generated docs (#129789)
Pulled from #128576 so it's easier to review.
2025-06-20 20:42:37 +01:00
Parker Timmins
245dc0775a
Make flattened synthetic source concatenate object keys on scalar/object mismatch (#129600)
There is an issue where for Flattened fields with synthetic source, if there is a key with a scalar value, and a duplicate key with an object value, one of the values will be left out of the produced synthetic source. This fixes the issue by replacing the object with paths to each of its keys. These paths consist of the concatenation of all keys going down to a given scalar, joined by a period. For example, they are of the form foo.bar.baz. This applies recursively, so that every value within the object, no matter how nested, will be accessible through a full specified path.
2025-06-20 14:20:49 -05:00
Lorenzo Dematté
1edf77c1df
Mute testSnapshotRestore in bcUpgradeTest (#129767) 2025-06-20 19:04:09 +01:00
Sam Xiao
706e7f3b6f
Make Watch transport actions project-aware (#129612) 2025-06-21 01:09:40 +08:00
Jonathan Buttner
d9b34d43a5
[ML] Custom service add support for input_type, top_n, and return_documents (#129441)
* Making progress on different request parameters

* Working tests

* Adding custom service validator for rerank

* Fixing embedding bug

* Adding transport version check

* Fixing tests

* Fixing license header

* Fixing writeTo

* Moving file and removing commented code

* Fixing test

* Fixing tests

* Refactoring and tests

* Fixing test
2025-06-20 12:23:48 -04:00
Niels Bauman
a230165df3
Unmute #112189 (#129773)
This test has been muted for a long time and only seemed to fail on v7
compatability tests. We're unmuting this to see if it's still relevant.

Closes #112189
2025-06-21 01:25:52 +10:00
Ignacio Vera
4ca96c199f
Introduce a vectorize soarDistance function (#129744)
This commit replaces the method #soarResidual with a method call #soarDistance which perfoms better for computing soar distances.
2025-06-20 16:23:50 +02:00
elasticsearchmachine
1d913f3da4 Mute org.elasticsearch.xpack.security.SecurityRolesMultiProjectIT testUpdatingFileBasedRoleAffectsAllProjects #129775 2025-06-20 23:56:55 +10:00
Carlos Delgado
6952cf2b63
Add IVF feature flag to IT tests (#129766) 2025-06-20 23:47:01 +10:00