Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -186,10 +186,14 @@
: (Required, string) Document that’s temporarily indexed in-memory and accessible from the script.

`index`
: (Required, string) Index containing a mapping that’s compatible with the indexed document. You may specify a remote index by prefixing the index with the remote cluster alias. For example, `remote1:my_index` indicates that you want to execute the painless script against the "my_index" index on the "remote1" cluster. This request will be forwarded to the "remote1" cluster if you have [configured a connection](docs-content://deploy-manage/remote-clusters/remote-clusters-self-managed.md) to that remote cluster.
: (Required, string) Index containing a mapping that’s compatible with the indexed document.

{applies_to}`stack: ga` When using {{ccs}}, you can specify a remote index by prefixing the index with the remote cluster alias. For example, `remote1:my_index` indicates that you want to execute the painless script against the "my_index" index on the "remote1" cluster or project. This request will be forwarded to the "remote1" cluster if you have [configured a connection](docs-content://deploy-manage/remote-clusters/remote-clusters-self-managed.md) to that remote cluster.

{applies_to}`serverless: preview` When [cross-project search](docs-content://explore-analyze/cross-project-search.md) (CPS) is enabled, an unqualified index name (for example, `logs`) targets the **origin project only**. Use `_origin:myindex` or `projectAlias:myindex` to target a specific project. [Project routing](docs-content://explore-analyze/cross-project-search/cross-project-search-project-routing.md) is not supported.

::::{note}
Wildcards are not accepted in the index expression for this endpoint. The expression `*:myindex` will return the error "No such remote cluster" and the expression `logs*` or `remote1:logs*` will return the error "index not found".

Check warning on line 196 in docs/reference/scripting-languages/painless/painless-api-examples.md

View workflow job for this annotation

GitHub Actions / build / vale

Elastic.QuotesPunctuation: Place punctuation inside closing quotation marks.
::::


Expand Down
Loading