Painless: Decouple PainlessLookupBuilder and Whitelists#32346
Merged
jdconrad merged 8 commits intoelastic:masterfrom Jul 25, 2018
Merged
Painless: Decouple PainlessLookupBuilder and Whitelists#32346jdconrad merged 8 commits intoelastic:masterfrom
jdconrad merged 8 commits intoelastic:masterfrom
Conversation
Collaborator
|
Pinging @elastic/es-core-infra |
Contributor
Author
|
@rjernst Removed the extraneous class and put whitelistsToPainlessLookup into PainlessLookupBuilder as we discussed. |
Contributor
Author
|
@elasticmachine test this please |
rjernst
approved these changes
Jul 24, 2018
Member
rjernst
left a comment
There was a problem hiding this comment.
Thanks, LGTM. Just one minor suggestion.
| private static final Pattern FIELD_NAME_PATTERN = Pattern.compile("^[_a-zA-Z][_a-zA-Z0-9]*$"); | ||
|
|
||
| private final List<Whitelist> whitelists; | ||
| public static PainlessLookup whitelistsToPainlessLookup(List<Whitelist> whitelists) { |
Member
There was a problem hiding this comment.
I would name this more simply like buildFromWhitelist.
Contributor
Author
|
@rjernst Thanks for the review. Will commit as soon as CI passes. |
jdconrad
added a commit
that referenced
this pull request
Jul 25, 2018
Implements a static function in PainlessLookupBuilder that contains all the logic related to Whitelist. PainlessLookupBuilder is available for use in loading from methods beyond Whitelist now.
dnhatn
added a commit
that referenced
this pull request
Jul 26, 2018
* master: [DOCS] Fix formatting error in Slack action Painless: Fix documentation links to use existing refs (#32335) Painless: Decouple PainlessLookupBuilder and Whitelists (#32346) [DOCS] Adds recommendation for xpack.security.enabled (#32345) [TEST] Mute ConvertProcessortTests.testConvertIntHexError [TEST] Fix failure due to exception message in java11 (#32321) [DOCS] Fixes typo in ML aggregations page [DOCS] Adds link from bucket_span property to common time units [ML][DOCS] Add documentation for detector rules and filters (#32013) Add opaque_id to index audit logging (#32260) Add 6.5.0 version to master fixes broken build for third-party-tests (#32353)
jasontedor
added a commit
to jasontedor/elasticsearch
that referenced
this pull request
Jul 26, 2018
* master: Only enforce password hashing check if FIPS enabled (elastic#32383) [DOCS] Fix formatting error in Slack action Painless: Fix documentation links to use existing refs (elastic#32335) Painless: Decouple PainlessLookupBuilder and Whitelists (elastic#32346)
dnhatn
added a commit
that referenced
this pull request
Jul 27, 2018
* 6.x: Only enforce password hashing check if FIPS enabled (#32383) Introduce fips_mode setting and associated checks (#32326) [DOCS] Fix formatting error in Slack action Ingest: Support integer and long hex values in convert (#32213) Release pipelined request in netty server tests (#32368) Add opaque_id to index audit logging (#32260) Painless: Fix documentation links to use existing refs (#32335) Painless: Decouple PainlessLookupBuilder and Whitelists (#32346) [DOCS] Adds recommendation for xpack.security.enabled (#32345) [test] package pre-install java check (#32259) [DOCS] Adds link from bucket_span property to common time units [DOCS] Fixes typo in ML aggregations page [ML][DOCS] Add documentation for detector rules and filters (#32013) Bump the 6.x branch to 6.5.0 (#32361) fixes broken build repository-s3 for third-party-tests
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.
Mostly a mechanical change. This moves all code related to the whitelists to a WhitelistsToPainlessLookup class so that PainlessLookupBuilder has no dependencies on the whitelists to build a PainlessLookup. This allows for Painless to create a Lookup from other sources moving forward which may have practical applications in both testing and jar separation shortly.