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

LUCENE-9353: revise format documentation of Lucene90BlockTreeTermsWriter #90

Merged
merged 2 commits into from
Apr 20, 2021

Conversation

mocobeta
Copy link
Contributor

@mocobeta mocobeta commented Apr 17, 2021

It seems that the javadocs needs to be revised. I tried to reflect the changes in apache/lucene-solr#1473 to the format description.

latest javadocs

javadoc_termswriter_current

generated javadocs with the patch

javadoc_termswriter

@mocobeta
Copy link
Contributor Author

@jpountz Could you take a look at this.

Copy link
Contributor

@jpountz jpountz left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thank you @mocobeta for fixing this!

* <li>TermsMeta (.tmd) --&gt; Header, NumFields, &lt;FieldStats&gt;<sup>NumFields</sup>,
* TermIndexLength, TermDictLength, Footer
* <li>FieldStats --&gt; FieldNumber, NumTerms, RootCodeLength, Byte<sup>RootCodeLength</sup>,
* SumTotalTermFreq?, SumDocFreq, DocCount, MinTerm, MaxTerm, IndexStartFP, FSTHeader,
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it is SumDocFreq which is not always specified rather than SumTotalTermFreq?

Suggested change
* SumTotalTermFreq?, SumDocFreq, DocCount, MinTerm, MaxTerm, IndexStartFP, FSTHeader,
* SumTotalTermFreq, SumDocFreq?, DocCount, MinTerm, MaxTerm, IndexStartFP, FSTHeader,

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm actually not the author of the line (I just moved it from the above section to here), but the specification seems to be correct to me.

if (fieldInfo.getIndexOptions() != IndexOptions.DOCS) {
metaOut.writeVLong(sumTotalTermFreq);
}
metaOut.writeVLong(sumDocFreq);

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woops I had misread!

Co-authored-by: Adrien Grand <jpountz@gmail.com>
@mocobeta mocobeta merged commit 5f5d194 into apache:main Apr 20, 2021
@mocobeta mocobeta deleted the jira/LUCENE-9353-update-javadoc branch April 20, 2021 22:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants