Add support for GeoShape to the scripting fields API#81617
Merged
jdconrad merged 6 commits intoelastic:masterfrom Jan 4, 2022
Merged
Add support for GeoShape to the scripting fields API#81617jdconrad merged 6 commits intoelastic:masterfrom
jdconrad merged 6 commits intoelastic:masterfrom
Conversation
Collaborator
|
Pinging @elastic/es-core-infra (Team:Core/Infra) |
49 tasks
Collaborator
|
Hi @jdconrad, I've created a changelog YAML for you. |
stu-elastic
reviewed
Dec 20, 2021
| private static final List<Whitelist> WHITELISTS = List.of( | ||
| WhitelistLoader.loadFromResourceFiles( | ||
| SpatialPainlessExtension.class, | ||
| "org.elasticsearch.xpack.spatial.index.fielddata.txt", |
Contributor
There was a problem hiding this comment.
Why split these across three different files?
Contributor
Author
There was a problem hiding this comment.
I find it easier to find the classes when they're separated out by package. I realize there's not a huge amount allow-listed here, yet, but I think we want to expand this quite a bit.
stu-elastic
reviewed
Dec 20, 2021
|
|
||
| public static class GeoShapeDocValuesField | ||
| implements | ||
| DocValuesField<GeoShapeValues.GeoShapeValue>, |
Contributor
There was a problem hiding this comment.
Is this formatting intended?
Contributor
Author
There was a problem hiding this comment.
Guess so since this is what spotless produced.
stu-elastic
approved these changes
Dec 20, 2021
Contributor
stu-elastic
left a comment
There was a problem hiding this comment.
Nice infrastructure.
Contributor
Author
|
@stu-elastic Thanks for the review! Will commit as soon as CI passes. |
astefan
pushed a commit
to astefan/elasticsearch
that referenced
this pull request
Jan 7, 2022
This change adds infrastructure for GeoShape making it accessible via the new scripting fields API. This does not add any methods outside of get at this point in time since it needs additional thought/discussion on what makes sense similar to GeoPoints. Note that because GeoShape does not support XContent this is just a skeleton that currently supports getScriptDocValues.
astefan
pushed a commit
to astefan/elasticsearch
that referenced
this pull request
Jan 7, 2022
This change adds infrastructure for GeoShape making it accessible via the new scripting fields API. This does not add any methods outside of get at this point in time since it needs additional thought/discussion on what makes sense similar to GeoPoints. Note that because GeoShape does not support XContent this is just a skeleton that currently supports getScriptDocValues.
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.
This change adds infrastructure for GeoShape making it accessible via the new scripting fields API. This does not add any methods outside of get at this point in time since it needs additional thought/discussion on what makes sense similar to GeoPoints. Note that because GeoShape does not support XContent this is just a skeleton that currently supports getScriptDocValues.