[
https://issues.apache.org/jira/browse/CASSANDRA-1902?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12978459#action_12978459
]
Peter Schuller commented on CASSANDRA-1902:
-------------------------------------------
Recommend is a strong word, but it was at least my initial reaction for the
simplicity of it. A threshold expressed in pages or bytes. I am definitely in
favor of an option above a hard-coded threshold, but that's coming from the
perspective of expecting to deploy in cache sensitive scenarios where CPU will
not be the main issue.
As for WILLNEED: I don't know enough about the kernel's page cache eviction to
say whether a write + WILLNEED will affect eviction relative to a write only.
Either way is plausible I think, without knowing. (e.g. if both write() and
WILLNEED is essentially counted as a 'hit' it might help; on the other hand it
might not if only page accesses are counted...). In either case, it's another
syscall.
> Migrate cached pages during compaction
> ---------------------------------------
>
> Key: CASSANDRA-1902
> URL: https://issues.apache.org/jira/browse/CASSANDRA-1902
> Project: Cassandra
> Issue Type: Improvement
> Components: Core
> Affects Versions: 0.7.1
> Reporter: T Jake Luciani
> Assignee: T Jake Luciani
> Fix For: 0.7.1
>
> Original Estimate: 32h
> Remaining Estimate: 32h
>
> Post CASSANDRA-1470 there is an opportunity to migrate cached pages from a
> pre-compacted CF during the compaction process.
> First, add a method to MmappedSegmentFile: long[] pagesInPageCache() that
> uses the posix mincore() function to detect the offsets of pages for this
> file currently in page cache.
> Then add getActiveKeys() which uses underlying pagesInPageCache() to get the
> keys actually in the page cache.
> use getActiveKeys() to detect which SSTables being compacted are in the os
> cache and make sure the subsequent pages in the new compacted SSTable are
> kept in the page cache for these keys. This will minimize the impact of
> compacting a "hot" SSTable.
> A simpler yet similar approach is described here:
> http://insights.oetiker.ch/linux/fadvise/
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.