Skip to content
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

ScriptDocValues.EMPTY doesn't implement getValue #5646

Closed
jpountz opened this issue Apr 1, 2014 · 1 comment
Closed

ScriptDocValues.EMPTY doesn't implement getValue #5646

jpountz opened this issue Apr 1, 2014 · 1 comment

Comments

@jpountz
Copy link
Contributor

jpountz commented Apr 1, 2014

This might not look like an issue since getting a single value on something that is empty makes no sense but it introduces an inconsistency between documents that have no value, depending on whether they are on a segment that has no value at all (which will use ScriptDocValues.EMPTY), or on a segment where at list one document has a value. In the latter case, ScriptDocValues.Longs (or Doubles) will be used and these classes implement getValue and return a default value (0) for documents with no value.

See #4684 (comment) for the original bug report.

@jpountz jpountz self-assigned this Apr 1, 2014
jpountz added a commit to jpountz/elasticsearch that referenced this issue Apr 1, 2014
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close elastic#5646
@s1monw
Copy link
Contributor

s1monw commented Apr 2, 2014

+1 to just remove the empty one!

jpountz added a commit that referenced this issue Apr 2, 2014
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close #5646
jpountz added a commit that referenced this issue Apr 2, 2014
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close #5646
jpountz added a commit that referenced this issue Apr 2, 2014
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close #5646
@jpountz jpountz closed this as completed in 4ff3e19 Apr 2, 2014
@jpountz jpountz added the v1.0.3 label Apr 2, 2014
mute pushed a commit to mute/elasticsearch that referenced this issue Jul 29, 2015
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close elastic#5646
mute pushed a commit to mute/elasticsearch that referenced this issue Jul 29, 2015
Instead the default implementation is used, but on top of empty
(Bytes|Long|Double|GeoPoint)Values. This makes sure there is no
inconsistency between documents depending on whether other documents in the
segment have values or not.

Close elastic#5646
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants