Issue Details (XML | Word | Printable)

Key: JRA-13296
Type: Improvement Improvement
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Brad Baker [Atlassian]
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
JIRA

JiraLuceneFieldCache is not a cache and the synchronized cache code should be removed

Created: 10/Aug/07 02:56 AM   Updated: 17/Jul/08 03:53 AM
Component/s: Performance, Refactoring
Affects Version/s: 3.10.1
Fix Version/s: None

Time Tracking:
Original Estimate: 4 hours
Original Estimate - 4 hours
Remaining Estimate: 4 hours
Remaining Estimate - 4 hours
Time Spent: Not Specified
Remaining Estimate - 4 hours

Issue Links:
Reference
 

Participants: Alexey Efimov, Brad Baker [Atlassian] and Scott Farquhar [Atlassian]
Since last comment: 12 weeks, 3 days ago
Labels:


 Description  « Hide
JiraLuceneFieldCache was a cache but now its not a cache but rather a Lucence document reader thingy and the synchronized "cache" code should be removed. The cache code doesn't actually cache anything but it does use synchronized calls and creates other useless objects on the stack. See Brad/Dylan for more details.

 All   Comments   Work Log   Change History      Sort Order: Ascending order - Click to sort in descending order
Scott Farquhar [Atlassian] added a comment - 27/Aug/07 01:57 AM
The LuceneFieldCache can now be turned back into a cache, which would help more now as we re-use the readers. We never used to re-use them, and that's why we turned the caching off.

Brad Baker [Atlassian] added a comment - 27/Aug/07 02:48 AM
The Lucene in Action books states (on page 199) "The sorting infrastructure within Lucene caches (based on a key combining the hashcode of the IndexReader, the field name and the custom sort object) the results of SortComparatorSource.newComparator"

So I would hazard a guess that Lucene is already caching this information for us any way and hence a secondary cache on top is not needed. This is probably why it never had a performance problem once the old caching "put" code was commented out.


Scott Farquhar [Atlassian] added a comment - 28/Aug/07 02:08 AM
Hey - am fine to remove it. You may just want to check the Lucene source code before you do.

Alexey Efimov added a comment - 17/Jul/08 03:53 AM
ping!