Examples of valuesOf()


Examples of joptsimple.OptionSet.valuesOf()

            } else if(options.has("fetch-entries")) {
                boolean useAscii = options.has("ascii");
                System.out.println("Starting fetch entries");
                List<Integer> partitionIdList = null;
                if(options.hasArgument("fetch-entries"))
                    partitionIdList = (List<Integer>) options.valuesOf("fetch-entries");
                executeFetchEntries(nodeId,
                                    adminClient,
                                    partitionIdList,
                                    outputDir,
                                    storeNames,
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

                                    useAscii,
                                    options.has("fetch-orphaned"));
            } else if(options.has("purge-slops")) {
                List<Integer> nodesToPurge = null;
                if(options.has("nodes")) {
                    nodesToPurge = (List<Integer>) options.valuesOf("nodes");
                }
                if(nodesToPurge == null && zoneId == -1 && storeNames == null) {
                    Utils.croak("Must specify atleast one of --nodes, --zone-id or --stores with --purge-slops");
                }
                executePurgeSlops(adminClient, nodesToPurge, zoneId, storeNames);
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

            } else if(options.has("show-routing-plan")) {
                if(!options.has("store")) {
                    Utils.croak("Must specify the store the keys belong to using --store ");
                }
                String storeName = (String) options.valueOf("store");
                List<String> keysToRoute = (List<String>) options.valuesOf("show-routing-plan");
                if(keysToRoute == null || keysToRoute.size() == 0) {
                    Utils.croak("Must specify comma separated keys list in hex format");
                }
                executeShowRoutingPlan(adminClient, storeName, keysToRoute);
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

        AdminTest adminTest;

        adminTest = new AdminTest(bootstrapUrl, storeName);

        SetMultimap<Integer, Integer> nodePartitions = adminTest.getNodePartitions(options.has("n") ? options.valuesOf("n")
                                                                                                   : null,
                                                                                   options.has("p") ? options.valuesOf("p")
                                                                                                   : null);

        if(options.has("f"))
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

        adminTest = new AdminTest(bootstrapUrl, storeName);

        SetMultimap<Integer, Integer> nodePartitions = adminTest.getNodePartitions(options.has("n") ? options.valuesOf("n")
                                                                                                   : null,
                                                                                   options.has("p") ? options.valuesOf("p")
                                                                                                   : null);

        if(options.has("f"))
            adminTest.testFetch(nodePartitions);
        if(options.has("fu"))
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

            List<String> storeNames = null;
            if(options.has("store") && options.has("stores")) {
                throw new VoldemortException("Must not specify both --stores and --store options");
            } else if(options.has("stores")) {
                storeNames = (List<String>) options.valuesOf("stores");
            } else if(options.has("store")) {
                storeNames = Arrays.asList((String) options.valueOf("store"));
            }

            String outputDir = null;
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

                executeAddStores(adminClient, storesXml, nodeId);
            } else if(options.has("async")) {
                String asyncKey = (String) options.valueOf("async");
                List<Integer> asyncIds = null;
                if(options.hasArgument("async-id"))
                    asyncIds = (List<Integer>) options.valuesOf("async-id");
                executeAsync(nodeId, adminClient, asyncKey, asyncIds);
            } else if(options.has("check-metadata")) {
                String metadataKey = (String) options.valueOf("check-metadata");
                executeCheckMetadata(adminClient, metadataKey);
            } else if(options.has("delete-partitions")) {
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

            } else if(options.has("check-metadata")) {
                String metadataKey = (String) options.valueOf("check-metadata");
                executeCheckMetadata(adminClient, metadataKey);
            } else if(options.has("delete-partitions")) {
                System.out.println("Starting delete-partitions");
                List<Integer> partitionIdList = (List<Integer>) options.valuesOf("delete-partitions");
                executeDeletePartitions(nodeId, adminClient, partitionIdList, storeNames);
                System.out.println("Finished delete-partitions");
            } else if(options.has("ro-metadata")) {
                String type = (String) options.valueOf("ro-metadata");
                executeROMetadata(nodeId, adminClient, storeNames, type);
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

            } else if(options.has("fetch-keys")) {
                boolean useAscii = options.has("ascii");
                System.out.println("Starting fetch keys");
                List<Integer> partitionIdList = null;
                if(options.hasArgument("fetch-keys"))
                    partitionIdList = (List<Integer>) options.valuesOf("fetch-keys");
                executeFetchKeys(nodeId,
                                 adminClient,
                                 partitionIdList,
                                 outputDir,
                                 storeNames,
View Full Code Here

Examples of joptsimple.OptionSet.valuesOf()

                                 useAscii,
                                 options.has("fetch-orphaned"));
            } else if(options.has("repair-job")) {
                executeRepairJob(nodeId, adminClient);
            } else if(options.has("set-metadata-pair")) {
                List<String> metadataKeyPair = (List<String>) options.valuesOf("set-metadata-pair");
                if(metadataKeyPair.size() != 2) {
                    throw new VoldemortException("Missing set-metadata-pair keys (only two keys are needed and allowed)");
                }
                if(!options.has("set-metadata-value-pair")) {
                    throw new VoldemortException("Missing set-metadata-value-pair");
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.