Package com.fasterxml.storemate.store.backend

Examples of com.fasterxml.storemate.store.backend.StoreBackend


            }
            backendConfig = _serviceStuff.convertValue(sconfig.storeBackendConfig, cfgType);
        }
        b = b.with(sconfig.storeConfig)
                .with(backendConfig);
        StoreBackend backend = b.build();
        StorableStore store = new StorableStoreImpl(sconfig.storeConfig, backend, _timeMaster,
                _serviceStuff.getFileManager(),
               constructThrottler(), constructWriteMutex());
        NodeStateStore<IpAndPort, ActiveNodeState> nodeStates = constructNodeStateStore(b);
        return constructStores(store, nodeStates);
View Full Code Here


     */

    protected ExternalMetrics _gatherMetrics(long creationTime, boolean fullStats)
    {
        ExternalMetrics metrics = new ExternalMetrics(creationTime);
        StoreBackend entries = _entryStore.getBackend();
        BackendStatsConfig conf = BACKEND_STATS_CONFIG
                .onlyCollectFast(!fullStats);
        metrics.stores.entries = _clean(entries.getEntryCount(), entries.getEntryStatistics(conf));
        metrics.stores.entryIndex = _clean(entries.getIndexedCount(), entries.getIndexStatistics(conf));
        if (_lastAccessStore != null) {
            metrics.stores.lastAccessStore = _clean(_lastAccessStore.getEntryCount(), _lastAccessStore.getEntryStatistics(conf));
        }

        AllOperationMetrics opMetrics = new AllOperationMetrics();
View Full Code Here

            if (v.storeBackendConfig == null) {
                throw new IllegalStateException("Missing 'v.storeBackendConfig");
            }
            backendConfig = stuff.convertValue(v.storeBackendConfig, cfgType);
        }
        StoreBackend backend = b.with(v.storeConfig)
                .with(backendConfig)
                .build();
        StorableStore store = new StorableStoreImpl(v.storeConfig, backend, _timeMaster,
               stuff.getFileManager(), _constructThrottler(stuff));
        return constructStores(stuff, v, store);
View Full Code Here

            if (v.storeBackendConfig == null) {
                throw new IllegalStateException("Missing 'v.storeBackendConfig");
            }
            backendConfig = stuff.convertValue(v.storeBackendConfig, cfgType);
        }
        StoreBackend backend = b.with(v.storeConfig)
                .with(backendConfig)
                .build();
        StorableStore store = new StorableStoreImpl(v.storeConfig, backend, _timeMaster,
               stuff.getFileManager());
        return constructStores(stuff, v, store);
View Full Code Here

            if (v.storeBackendConfig == null) {
                throw new IllegalStateException("Missing 'VagabondServiceConfig.storeBackendConfig");
            }
            backendConfig = stuff.convertValue(v.storeBackendConfig, cfgType);
        }
        StoreBackend backend = b.with(v.storeConfig)
                .with(backendConfig)
                .build();
        StorableStore store = new StorableStoreImpl(v.storeConfig, backend, _timeMaster,
               stuff.getFileManager());
        return constructStores(stuff, v, store);
View Full Code Here

     */

    protected ExternalMetrics _gatherMetrics(long creationTime, boolean fullStats)
    {
        ExternalMetrics metrics = new ExternalMetrics(creationTime);
        StoreBackend entries = _entryStore.getBackend();
        BackendStatsConfig conf = BACKEND_STATS_CONFIG;
        if (fullStats) {
            conf = conf.onlyCollectFast(false);
        }
        metrics.stores.entries = new BackendMetrics(creationTime,
                entries.getEntryCount(),
                _clean(entries.getEntryStatistics(BACKEND_STATS_CONFIG)));
        metrics.stores.entryIndex = new BackendMetrics(creationTime,
                entries.getIndexedCount(),
                _clean(entries.getIndexStatistics(BACKEND_STATS_CONFIG)));
        metrics.stores.lastAccessStore = new BackendMetrics(creationTime,
                _lastAccessStore.getEntryCount(),
                _clean(_lastAccessStore.getEntryStatistics(BACKEND_STATS_CONFIG)));

        AllOperationMetrics opMetrics = new AllOperationMetrics();
View Full Code Here

            if (v.storeBackendConfig == null) {
                throw new IllegalStateException("Missing 'VagabondServiceConfig.storeBackendConfig");
            }
            backendConfig = stuff.convertValue(v.storeBackendConfig, cfgType);
        }
        StoreBackend backend = b.with(v.storeConfig)
                .with(backendConfig)
                .build();
        StorableStore store = new StorableStoreImpl(v.storeConfig, backend, _timeMaster,
               stuff.getFileManager());
        return constructStores(stuff, v, store);
View Full Code Here

    {
        File testRoot = getTestScratchDir(nameSuffix, true);
        File fileDir = new File(testRoot, "files");
        StoreConfig storeConfig = new StoreConfig();
        FileManagerConfig fmConfig = new FileManagerConfig(fileDir);
        StoreBackend backend = createBackend(testRoot, storeConfig);
        return new StorableStoreImpl(storeConfig, backend, timeMaster,
                new FileManager(fmConfig, timeMaster, new DefaultFilenameConverter()),
                null, null);
    }
View Full Code Here

    }
   
    protected void _verifyEntryCount(long exp, StorableStore store)
        throws StoreException
    {
        StoreBackend backend = store.getBackend();
        if (backend.hasEfficientEntryCount()) {
            assertEquals(exp, backend.getEntryCount());
        }
        // but let's also verify via actual iteration?
        assertEquals(exp, backend.countEntries());
    }
View Full Code Here

    }

    protected void _verifyIndexCount(long exp, StorableStore store)
        throws StoreException
    {
        StoreBackend backend = store.getBackend();
        if (backend.hasEfficientIndexCount()) {
            assertEquals(exp, backend.getIndexedCount());
        }
        // but let's also verify via actual iteration?
        assertEquals(exp, backend.countIndexed());
    }
View Full Code Here

TOP

Related Classes of com.fasterxml.storemate.store.backend.StoreBackend

Copyright © 2018 www.massapicom. 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.