Examples of KeyCacheKey


Examples of org.apache.cassandra.cache.KeyCacheKey

            || keyCache.getCapacity() == 0)
        {
            return;
        }

        KeyCacheKey cacheKey = new KeyCacheKey(metadata.cfId, descriptor, key.key);
        logger.trace("Adding cache entry for {} -> {}", cacheKey, info);
        keyCache.put(cacheKey, info);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        }
    }

    public RowIndexEntry getCachedPosition(DecoratedKey key, boolean updateStats)
    {
        return getCachedPosition(new KeyCacheKey(metadata.cfId, descriptor, key.key), updateStats);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        // next, the key cache (only make sense for valid row key)
        if ((op == Operator.EQ || op == Operator.GE) && (key instanceof DecoratedKey))
        {
            DecoratedKey decoratedKey = (DecoratedKey)key;
            KeyCacheKey cacheKey = new KeyCacheKey(metadata.cfId, descriptor, decoratedKey.key);
            RowIndexEntry cachedPosition = getCachedPosition(cacheKey, updateCacheAndStats);
            if (cachedPosition != null)
            {
                Tracing.trace("Key cache hit for sstable {}", descriptor.generation);
                return cachedPosition;
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        writer.close();
        Descriptor desc = directories.sstableLister().list().keySet().iterator().next();

        File cachePath = CacheService.instance.keyCache.getCachePath(ks, cf);
        SequentialWriter out = SequentialWriter.open(cachePath);
        new KeyCacheKey(desc, key).write(out.stream);
        out.close();

        ColumnFamilyStore cfs = Table.open(ks).getColumnFamilyStore(cf);
        cfs.disableAutoCompaction();
        SSTableReader sstable = cfs.getSSTables().iterator().next();
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

            || keyCache.getCapacity() == 0)
        {
            return;
        }

        KeyCacheKey cacheKey = new KeyCacheKey(descriptor, key.key);
        logger.trace("Adding cache entry for {} -> {}", cacheKey, info);
        keyCache.put(cacheKey, info);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        keyCache.put(cacheKey, info);
    }

    public RowIndexEntry getCachedPosition(DecoratedKey key, boolean updateStats)
    {
        return getCachedPosition(new KeyCacheKey(descriptor, key.key), updateStats);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        // next, the key cache (only make sense for valid row key)
        if ((op == Operator.EQ || op == Operator.GE) && (key instanceof DecoratedKey))
        {
            DecoratedKey decoratedKey = (DecoratedKey)key;
            KeyCacheKey cacheKey = new KeyCacheKey(descriptor, decoratedKey.key);
            RowIndexEntry cachedPosition = getCachedPosition(cacheKey, updateCacheAndStats);
            if (cachedPosition != null)
            {
                logger.trace("Cache hit for {} -> {}", cacheKey, cachedPosition);
                logger.debug("Key cache hit for sstable {}", descriptor.generation);
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        return positions;
    }

    public void invalidateCacheKey(DecoratedKey key)
    {
        KeyCacheKey cacheKey = new KeyCacheKey(metadata.cfId, descriptor, key.getKey());
        keyCache.remove(cacheKey);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

            || keyCache.getCapacity() == 0)
        {
            return;
        }

        KeyCacheKey cacheKey = new KeyCacheKey(metadata.cfId, descriptor, key.getKey());
        logger.trace("Adding cache entry for {} -> {}", cacheKey, info);
        keyCache.put(cacheKey, info);
    }
View Full Code Here

Examples of org.apache.cassandra.cache.KeyCacheKey

        keyCache.put(cacheKey, info);
    }

    public RowIndexEntry getCachedPosition(DecoratedKey key, boolean updateStats)
    {
        return getCachedPosition(new KeyCacheKey(metadata.cfId, descriptor, key.getKey()), updateStats);
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.