Examples of AdminClient


Examples of com.dotcms.repackage.org.elasticsearch.client.AdminClient

    /**
     * returns cluster health
     * @return
     */
    public Map<String,ClusterIndexHealth> getClusterHealth() {
        AdminClient client=new ESClient().getClient().admin();

        ClusterHealthRequest req = new ClusterHealthRequest();
        ActionFuture<ClusterHealthResponse> chr = client.cluster().health(req);

        ClusterHealthResponse res  = chr.actionGet();
        Map<String,ClusterIndexHealth> map  = res.getIndices();

        return map;
View Full Code Here

Examples of com.ibm.websphere.management.AdminClient

        if(config.getUsername() != null && config.getUsername().trim().length() > 0){
            adminProps.setProperty(AdminClient.USERNAME, config.getUsername());
            adminProps.setProperty(AdminClient.PASSWORD, config.getPassword());
        }
        try{
            AdminClient adminClient = AdminClientFactory.createAdminClient(adminProps);
            return new WebSphereServerConnection(adminClient);
        }catch(Throwable e){
            throw new ConnectionFailedException(e);
        }
    }
View Full Code Here

Examples of net.greghaines.jesque.admin.AdminClient

        adminThread.start();

        Assert.assertFalse(worker.isPaused());

        try {
            final AdminClient adminClient = new AdminClientImpl(config);
            try {
                adminClient.togglePausedWorkers(true);
                try {
                    Thread.sleep(1000L);
                } catch (InterruptedException ie) {
                }
                Assert.assertTrue(worker.isPaused());

                Assert.assertFalse(worker.isShutdown());
                adminClient.shutdownWorkers(true);
                try {
                    Thread.sleep(1000L);
                } catch (InterruptedException ie) {
                }
                Assert.assertTrue(worker.isShutdown());
            } finally {
                adminClient.end();
            }
        } finally {
            TestUtils.stopWorker(admin, adminThread);
            TestUtils.stopWorker(worker, workerThread);
        }
View Full Code Here

Examples of org.apache.axis.client.AdminClient

            }
        }
        axisServer.setServerSocket(socket);
        try {
            axisServer.start(true);
            AdminClient admin = new AdminClient();
            Options opts = new Options(new String[] {"-p", Integer.toString(AXIS_PORT)});
            InputStream is = getClass().getResourceAsStream("resources/echoDeploy.wsdd");
            String result = admin.process(opts, is);
            if (null == result || result.contains("AxisFault")) {
                throw new Exception("Failed to start axis server");
            }
        } catch (Exception ex) {
            System.err.println("Failed to deploy echo axis server.");
View Full Code Here

Examples of org.apache.axis.client.AdminClient

            serverConfig.delete();
        }
    }

    protected boolean verify(Logger l) {
        AdminClient admin = new AdminClient();
        try {
            Options opts = new Options(new String[] {"-p", Integer.toString(AXIS_PORT)});
            InputStream is = getClass().getResourceAsStream("resources/echoUndeploy.wsdd");
            String result = admin.process(opts, is);
            if (null == result || result.contains("AxisFault")) {
                return false;
            }
            admin.quit(opts);
        } catch (Exception ex) {
            return false;
        }
        return true;
    }
View Full Code Here

Examples of org.apache.axis.client.AdminClient

            args[counter] = arg;
            counter++;
        }

        //now create a client and invoke it
        AdminClient admin = new AdminClient();
        String result = null;
        try {
            result = admin.process(args);
            if (result != null) {
                log(result);
            } else {
                logOrThrow(getTaskName() + " got a null response");
            }
View Full Code Here

Examples of org.apache.axis.client.AdminClient

            args[counter] = arg;
            counter++;
        }

        //now create a client and invoke it
        AdminClient admin = new AdminClient();
        String result = null;
        try {
            result = admin.process(args);
            if (result != null) {
                log(result);
            } else {
                logOrThrow(getTaskName() + " got a null response");
            }
View Full Code Here

Examples of org.elasticsearch.client.AdminClient

     * @return true if exists
     */
    public static boolean existsIndex(String indexName) {

        Client client = IndexClient.client;
        AdminClient admin = client.admin();
        IndicesAdminClient indices = admin.indices();
        IndicesExistsRequestBuilder indicesExistsRequestBuilder = indices.prepareExists(indexName);
        IndicesExistsResponse response = indicesExistsRequestBuilder.execute().actionGet();

        return response.isExists();
    }
View Full Code Here

Examples of voldemort.client.protocol.admin.AdminClient

                                                                                new Properties());
            VoldemortServer vs = ServerTestUtils.startVoldemortServer(ssf, config, cluster);
            vservers.put(node.getId(), vs);
            socketStoreFactories.put(node.getId(), ssf);
        }
        adminClient = new AdminClient(cluster, new AdminClientConfig(), new ClientConfig());
    }
View Full Code Here

Examples of voldemort.client.protocol.admin.AdminClient

            }
        }

        Properties adminProperties = new Properties();
        adminProperties.setProperty("max_connections", "2");
        adminClient = new AdminClient(servers[0].getMetadataStore().getCluster(),
                                      new AdminClientConfig(adminProperties),
                                      new ClientConfig());
    }
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.