-
Notifications
You must be signed in to change notification settings - Fork 24.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Disable using unsigned_long in scripts #64523
Disable using unsigned_long in scripts #64523
Conversation
Pinging @elastic/es-search (:Search/Search) |
@mayya-sharipova I believe this also needs a change in |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mayya-sharipova. The change reverted the added code. I've test that it throws a runtime error when a unsigned_long
field is accessed from a script:
"failed_shards": [
{
"shard": 0,
"index": "ul_test",
"node": "94nQZ39ZR5SQnah5MN0d_w",
"reason": {
"type": "script_exception",
"reason": "runtime error",
"script_stack": [
"org.elasticsearch.xpack.unsignedlong.UnsignedLongLeafFieldData.getScriptValues(UnsignedLongLeafFieldData.java:77)",
"org.elasticsearch.search.lookup.LeafDocLookup$1.run(LeafDocLookup.java:72)",
"org.elasticsearch.search.lookup.LeafDocLookup$1.run(LeafDocLookup.java:69)",
"java.base/java.security.AccessController.doPrivileged(Native Method)",
"org.elasticsearch.search.lookup.LeafDocLookup.get(LeafDocLookup.java:69)",
"org.elasticsearch.search.lookup.LeafDocLookup.get(LeafDocLookup.java:36)",
"state.sqrd.add(doc.a.value * doc.a.value)",
" ^---- HERE"
],
"script": "state.sqrd.add(doc.a.value * doc.a.value)",
"lang": "painless",
"position": {
"offset": 18,
"start": 0,
"end": 41
},
"caused_by": {
"type": "unsupported_operation_exception",
"reason": "Using unsigned_long in scripts is currently not supported!"
}
}
}
]
Backport for elastic#64523 Relates to elastic#64361
Backport for elastic#64523 Relates to elastic#64361
Relates to #60050, and #64361