Watcher history index has too many indexed fields - (#71479)#117701
Watcher history index has too many indexed fields - (#71479)#117701lukewhiting merged 9 commits intoelastic:mainfrom
Conversation
|
Pinging @elastic/es-data-management (Team:Data Management) |
|
Hi @lukewhiting, I've created a changelog YAML for you. |
5fa1921 to
10a0403
Compare
|
Hi @lukewhiting, I've created a changelog YAML for you. |
dakrone
left a comment
There was a problem hiding this comment.
LGTM, I left two minor comments
x-pack/plugin/core/template-resources/src/main/resources/watch-history-no-ilm.json
Outdated
Show resolved
Hide resolved
| { | ||
| "index_patterns": [ ".watcher-history-${xpack.watcher.template.version}*" ], | ||
| "priority": 2147483647, | ||
| "priority": 2147483648, |
There was a problem hiding this comment.
Also 2147483647 was Integer.MAX_VALUE, right? I'm not sure anything bad happens if we exceed that, but it seems interesting.
There was a problem hiding this comment.
As above, reverted.
Also 2147483647 was Integer.MAX_VALUE, right? I'm not sure anything bad happens if we exceed that, but it seems interesting.
Just at of interest I was playing about with this, the code did seem to happily accept this priority value in a template and correctly store and return it without overflowing or erroring... That said, I would not be supprised if it overflows at some point when doing comparisons to other priorities and silently evaluates this as -2147483646.
…tcher-history-too-many-fields
…tcher-history-too-many-fields
…tcher-history-too-many-fields
…lastic#117701) * Exclude result.input.chain from watcher history index mappings * Update docs/changelog/117701.yaml * Fixup text now fields are disabled higher up the chain * Revert priority change
💚 Backport successful
|
This pull request includes updates to the Watcher Index Template Registry and associated JSON templates to exclude the input chain fields from the .watcher-history index from being mapped. This prevents the
field expansion matches too many fields, limit: 1024, got: 1406error when the chain is complex.Changes to Watcher Index Template Registry:
INDEX_TEMPLATE_VERSIONto 17 inWatcherIndexTemplateRegistryFieldto reflect the exclusion of the input chain from indexing and added comment for new version numberChanges to JSON templates:
watch-history-no-ilm.jsontemplate to 2147483647 and added a new dynamic template to disable indexing forresult.input.chain. [1] [2]watch-history.jsontemplate to 2147483648 and added a new dynamic template to disable indexing forresult.input.chain. [1] [2]Fixes #71479