Skip to content

Whitelist expansion#18372

Merged
rmuir merged 1 commit intoelastic:masterfrom
rmuir:painless_whitelist_expansion
May 16, 2016
Merged

Whitelist expansion#18372
rmuir merged 1 commit intoelastic:masterfrom
rmuir:painless_whitelist_expansion

Conversation

@rmuir
Copy link
Copy Markdown
Contributor

@rmuir rmuir commented May 16, 2016

Most of these improvements focus on the basic types:

  • add compare/compareTo/toHexString/parseX for basic types
  • add Integer/Long/Float/Double min/max and remove the imax/lmax stuff
  • add Character methods like isWhiteSpace and similar
  • add Math E and PI constants.

We need to followup with docs improvements (its already out of date anyway). In general I think the way we present that needs to be re-organized completely. There is a lot more to do here, but these changes are all simple and easy.

@jdconrad
Copy link
Copy Markdown
Contributor

LGTM. Thanks for adding more!

@uschindler
Copy link
Copy Markdown
Contributor

Do we also have some real read/write on fields, so we can check painless DefField class? Static fields don't help... Currently there is no way to test the code!

@rmuir
Copy link
Copy Markdown
Contributor Author

rmuir commented May 16, 2016

This PR is really just to capture "easy wins". I know the problem there, but we should solve it differently IMO. I also omitted any date apis or similar here for the same reason. They are more complex.

@jdconrad
Copy link
Copy Markdown
Contributor

@uschindler So there were actually tests for this before, but they got removed when we decided to make Definition a singleton. It should be possible to have a dummy dictionary again for field tests, but this should probably be a separate issue.

@rmuir rmuir merged commit e69305a into elastic:master May 16, 2016
@uschindler
Copy link
Copy Markdown
Contributor

@jdconrad thanks for this. I think this is ok for now. I'd suggest to add some "undocumented" fake class for testing that is added to the Definition.

@clintongormley clintongormley changed the title painless whitelist expansion Whitelist expansion May 17, 2016
@jdconrad jdconrad mentioned this pull request May 17, 2016
18 tasks
@clintongormley clintongormley added :Core/Infra/Scripting Scripting abstractions, Painless, and Mustache and removed :Plugin Lang Painless labels Feb 14, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

:Core/Infra/Scripting Scripting abstractions, Painless, and Mustache >enhancement v5.0.0-alpha3

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants