After the `IndexTemplateRegistry` was made project-aware in #126986,
we were seeing timeouts of the MP version of the x-pack YAML test suite.
The original version has a timeout of 60 minutes but the MP-version
still had a timeout of 30 minutes. We've gotten away with that
difference because there are still tests on the blacklist for the MP
version, but now that we're making more and more features project-aware,
we need to align the timeout.
Fixes#127433
Mainly moves project setup from `MultipleProjectsClientYamlSuiteTestCase` to
`ESRestTestCase`. This allows both Java REST tests and YAML tests to be run
in MP mode by passing the system property `-Dtests.multi_project.enabled=true`.
Future work will add the required gradle changes to be able to run any REST test in
MP mode more easily.
This converts this class to support multi-project.
There is a drive-by refactoring to split multiple independent tests in one method into separate methods. (Look at this change with whitespace changes hidden to see the 'real' change.)
* [main] Move system indices migration to migrate plugin
It seems the best way to fix#122949 is to use existing data stream reindex API. However, this API is located in the migrate x-pack plugin. This commit moves the system indices migration logic (REST handlers, transport actions, and task) to the migrate plugin.
Port of #123551
* [CI] Auto commit changes from spotless
* Fix compilation
* Fix tests
* Fix test
---------
Co-authored-by: elasticsearchmachine <infra-root+elasticsearchmachine@elastic.co>
This makes using usesDefaultDistribution in our test setup for explicit by requiring a reason why it's needed.
This is helpful as part of revisiting the need for all those usages in our code base.
Makes the execution and use of enrich policies project-aware.
Note: this does not make the enrich cache project-aware. That is to be
handled in a follow-up PR.
* Fix Gradle Deprecation warning as declaring an is- property with a Boolean type has been deprecated.
* Make use of new layout.settingsFolder api to address some cross project references
* Fix buildParams snapshot check for multiprojet projects
This cleans up the exclusion list for
`xpack-rest-tests-with-multiple-projects` to enable some working tests
and be more explicit about which tests are disabled.
The PUT and DELETE APIs were already project aware, but pushed the
project resolver into the cluster state update task. This commit pushes
the project id down instead - which is consistent with other actions
that have been made project aware.
Additionally, this commit makes the GET ILM policy project aware and it
includes ILM's YAML REST tests in the multi-project test suite.
This unmutes a number of security-related YAML tests that correctly
function now that we have merged the following PRs
- MP-1752
- MP-1755
- MP-1764
- MP-1771
- MP-1772
- MP-1775
- MP-1782
In the multi-project yaml rest tests, switch to using the routing table
(from cluster state, see MP-1695) to determine that the projects have been
correctly created and configured in the test client.