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

ISPN-4505 Lucene Directory polishing #2706

Closed
wants to merge 1 commit into from

Conversation

gustavocoding
Copy link

No description provided.

@@ -269,7 +255,7 @@ private Boolean containsKeyIntern(final ChunkCacheKey chunkCacheKey) throws IOEx
final long length = directory.fileLength(chunkCacheKey.getFileName());
final int bufferSize = chunkCacheKey.getBufferSize();
final int chunkId = chunkCacheKey.getChunkId();
return Boolean.valueOf((chunkId * bufferSize) < (length + bufferSize));
Copy link
Member

Choose a reason for hiding this comment

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

Since auto-boxing can be a performance pain when it happens unintentionally, we made the choice to set IDEs to flag these as a warning, hence it's preferrable to keep it as an explicit operation when we need to use the "uppercase versions" of primitives.

@Sanne
Copy link
Member

Sanne commented Jul 13, 2014

Thanks Gustavo! I reverted the couple of auto-boxing changes - especially as they didn't seem related with the overall issue at hand - and then applied it. I'd normally should have waited but there where lots of nice improvements at risk of conflicts, so I went ahead.
I've also added two more commits which where extremely trivial, so pushed them too.

@Sanne Sanne closed this Jul 13, 2014
@gustavocoding gustavocoding deleted the ISPN-4505 branch November 27, 2014 10:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants