Package co.paralleluniverse.spacebase.quasar

Examples of co.paralleluniverse.spacebase.quasar.SpaceBaseBuilder


        println("Node width: " + nodeWidth);
        println("Compressed: " + compressed);
        println("Single precision: " + singlePrecision);
        println();

        SpaceBaseBuilder builder = new SpaceBaseBuilder();

        if (glxNode > 0)
            builder.setStore(GalaxyStore.class);

        builder.setQueueBackpressure(1000);

        if (optimistic)
            builder.setOptimisticLocking(optimisticHeight, optimisticRetryLimit);
        else
            builder.setPessimisticLocking();

        builder.setDimensions(2);

        builder.setSinglePrecision(singlePrecision).setCompressed(compressed);
        builder.setNodeWidth(nodeWidth);

        builder.setMonitoringType(MonitorType.JMX);
        if (metricsDir != null) {
            com.codahale.metrics.CsvReporter.forRegistry(Metrics.registry())
                    .convertRatesTo(TimeUnit.SECONDS)
                    .convertDurationsTo(TimeUnit.MILLISECONDS)
                    .build(metricsDir)
                    .start(1, TimeUnit.SECONDS);
        }

        final SpaceBase<Record<SpaceshipState>> space = builder.build("base1");

        if (glxNode > 0) {
            GalaxyStore store = (GalaxyStore) space.getStore();
//            store.addMigrationListener(new MigrationListener<Record<SpaceshipState>>() {
//
View Full Code Here

TOP

Related Classes of co.paralleluniverse.spacebase.quasar.SpaceBaseBuilder

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.