[ 
https://issues.apache.org/jira/browse/LUCENE-1798?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12747570#action_12747570
 ] 

Hoss Man commented on LUCENE-1798:
----------------------------------

bq. I suppose we could switch to InsanityMonitor but then provide a 
PrintStreamInstanityMonitor impl... still seems kinda overkill though.

...that was what i had in mind, but you're right -- it is overkill.  a 
PrintStream is a nice quick and easy way to get this info -- if they really 
want robust data structures they can use the sanity checker directly (possibly 
even from a mock PrintStream)

bq. I agree we could make LuceneTestCase.tearDown more robust if tap into this, 
though the simple infoStream could also be used for that? ... sure, because if 
*anything* gets written to that stream, it indicates a bug ... unless they 
expect it, in which case they can catch an exception an ignore it.

but the LuceneTestCase changes are less urgent ... i was mainly worried about 
making surewe were happy with the API.  You've convinced me.

> FieldCacheSanityChecker called directly by FieldCache.get*
> ----------------------------------------------------------
>
>                 Key: LUCENE-1798
>                 URL: https://issues.apache.org/jira/browse/LUCENE-1798
>             Project: Lucene - Java
>          Issue Type: Improvement
>          Components: Search
>            Reporter: Hoss Man
>            Assignee: Michael McCandless
>             Fix For: 2.9
>
>         Attachments: LUCENE-1798.patch, LUCENE-1798.patch
>
>
> As suggested by McCandless in LUCENE-1749, we can make FieldCacheImpl a 
> client of the FieldCacheSanityChecker and have it sanity check itself each 
> time it creates a new cache entry, and log a warning if it thinks there is a 
> problem.  (although we'd probably only want to do this if the caller has set 
> some sort of infoStream/warningStream type property on the FieldCache object.

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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

Reply via email to