in trunk if you switch up omitNorms while indexing, you get a corrumpt norms 
file
---------------------------------------------------------------------------------

                 Key: LUCENE-3619
                 URL: https://issues.apache.org/jira/browse/LUCENE-3619
             Project: Lucene - Java
          Issue Type: Bug
    Affects Versions: 4.0
            Reporter: Robert Muir


document 1 has 
  body: norms=true
  title: norms=true
document 2 has 
  body: norms=false
  title: norms=true

when seeing 'body' for the first time, normswriterperfield gets 'initial 
fieldinfo' and 
saves it away, which says norms=true

however, at flush time we dont check, so we write the norms happily anyway.
then SegmentReader reads the norms later: it skips "body" since it omits norms
and if you ask for the norms of 'title' it instead returns the bogus "body" 
norms.

asserting that SegmentReader "plans to" read the whole .nrm file exposes the 
bug.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: 
https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to