[
https://issues.apache.org/jira/browse/LUCENE-5992?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14160155#comment-14160155
]
Uwe Schindler edited comment on LUCENE-5992 at 10/6/14 10:22 AM:
-----------------------------------------------------------------
About the "fixed format" issue (if we for example in future remove add
components): We could theoretically write another prefix byte as marker for the
version format? Not sure if this is really good, it would just be a possibility
to change the encoding format.
About the public version ctor: I don't like this. Initially I thougth CodecUtil
is part of util package, too, so it could be pkg-protected, but this is not the
case :-( In general I would instead prefer to have the ctor hidden again, but
add some static method with good comment not to use it. A ctor always makes
people try to use it, especially because of Eclipse autocomplete. So better use
Version.buildFromComponents(major, minor,...). This would also be consistent
with parse* API.
was (Author: thetaphi):
About the "fixed format" issue (if we for example in future remove add
components): We could theoretically write another prefix byte as marker for the
version format? Not sure if this is really good, it would just be a possibility
to change the encoding format.
About the public version ctor: I don't like this. Initially I thougth CodecUtil
is part of util package, too, so it could be pkg-protected, but this is not the
case :-( In general I would instead prefer to have the ctor hidden again, but
add some static method with good comment not to use it. A ctor always makes
people try to use it, especially because of Eclipse autocomplete. So better use
Version.buildFromComponents(major, minor,...).
> Version should not be encoded as a String in the index
> ------------------------------------------------------
>
> Key: LUCENE-5992
> URL: https://issues.apache.org/jira/browse/LUCENE-5992
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: Michael McCandless
> Assignee: Michael McCandless
> Fix For: 5.0, Trunk
>
> Attachments: LUCENE-5992.patch
>
>
> The version is really "just" 3 (maybe 4) ints under-the-hood, but today we
> write it as a String which then requires spooky string tokenization/parsing
> when we open the index. I think it should be encoded directly as ints.
> In LUCENE-5952 I had tried to make this change, but it was controversial, and
> got booted.
> Then in LUCENE-5969, I tried again, but that issue has morphed (nicely!) into
> fixing all sorts of things *except* these three ints.
> Maybe 3rd time's a charm ;)
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]