[Rollup] Better error message when trying to set non-rollup index#32965
Merged
polyfractal merged 4 commits intoelastic:masterfrom Aug 28, 2018
Merged
[Rollup] Better error message when trying to set non-rollup index#32965polyfractal merged 4 commits intoelastic:masterfrom
polyfractal merged 4 commits intoelastic:masterfrom
Conversation
We don't allow the user to configure a rollup index against an existing index, but the exceptions that we return are not clear about that. They indicate issues with metadata, instead of stating the real reason (not allowed to use a non-rollup index to store rollup data). This makes the exception better, and adds a bit more testing
Collaborator
|
Pinging @elastic/es-search-aggs |
Contributor
Author
|
@colings86 figured I'd give Jim a break on reviews, mind taking a look at this? Should be quick/easy :) |
colings86
reviewed
Aug 24, 2018
| Object m = mappings.getSourceAsMap().get("_meta"); | ||
| if (m == null) { | ||
| String msg = "Expected to find _meta key in mapping of rollup index [" + indexName + "] but not found."; | ||
| String msg = "Rollup indices cannot co-mingle with non-rollup data (expected to find _meta key in " + |
Contributor
There was a problem hiding this comment.
I think co-exist might be better than co-mingle here? Also this message might still be a little confusing because its comparing a Rollup indices with non-rollup data, should we instead say either called both indices or both data?
| + "] but not found."; | ||
| String msg = "Rollup indices cannot co-mingle with non-rollup data (expected to find " + | ||
| "rollup meta key [" + RollupField.ROLLUP_META + "] in mapping of rollup index [" | ||
| + indexName + "] but not found)."; |
added 2 commits
August 27, 2018 14:48
Contributor
Author
|
@colings86 👍 rewrote the messages, they were just as confusing as the pre-PR messages (oops). Hopefully less vague and more helpful now :) |
polyfractal
pushed a commit
that referenced
this pull request
Aug 28, 2018
…2965) We don't allow the user to configure a rollup index against an existing index, but the exceptions that we return are not clear about that. They indicate issues with metadata, instead of stating the real reason (not allowed to use a non-rollup index to store rollup data). This makes the exception better, and adds a bit more testing
dnhatn
added a commit
that referenced
this pull request
Aug 28, 2018
* master: [Rollup] Better error message when trying to set non-rollup index (#32965) HLRC: Use Optional in validation logic (#33104) Remove unused User class from protocol (#33137) ingest: Introduce the dissect processor (#32884) [Docs] Add link to es-kotlin-wrapper-client (#32618) [Docs] Remove repeating words (#33087) Minor spelling and grammar fix (#32931) Remove support for deprecated params._agg/_aggs for scripted metric aggregations (#32979) Watcher: Simplify finding next date in cron schedule (#33015) Run Third party audit with forbidden APIs CLI (part3/3) (#33052) Fix plugin build test on Windows (#33078) HLRC+MINOR: Remove Unused Private Method (#33165) Remove old unused test script files (#32970) Build analysis-icu client JAR (#33184) Ensure to generate identical NoOp for the same failure (#33141) ShardSearchFailure#readFrom to set index and shardId (#33161)
dnhatn
added a commit
that referenced
this pull request
Aug 28, 2018
* 6.x: [Rollup] Better error message when trying to set non-rollup index (#32965) Remove unused User class from protocol (#33137) [DOCS] Adds link to 6.3.0 release highlights Test: fix token bwc tests due to bad backport Ensure to generate identical NoOp for the same failure (#33141) [Docs] Add link to es-kotlin-wrapper-client (#32618) [Docs] Remove repeating words (#33087) Minor spelling and grammar fix (#32931) Run Third party audit with forbidden APIs CLI (part3/3) (#33052) Fix plugin build test on Windows (#33078) Watcher: Simplify finding next date in cron schedule (#33015) Remove old unused test script files (#32970) Build analysis-icu client JAR (#33184) Switch remaining tests to new style Requests (#33109) Use internal connection manager when fetching remote node info Switch remaining x-pack tests to new style Requests (#33108) Switch remaining ml tests to new style Requests (#33107) Token API supports the client_credentials grant (#33106)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
We don't allow the user to configure a rollup index against an existing index, but the exceptions that we return are not clear about that. They indicate issues with metadata, instead of stating the real reason (not allowed to use a non-rollup index to store rollup data).
This makes the exception better, and adds a bit more testing