Examples of executeRequest()


Examples of com.cloud.hypervisor.hyperv.resource.HypervDirectConnectResource.executeRequest()

            resource.configure(agentIp, params);

            // Assert
            // TODO: test by using bogus URL and bogus virtual path in URL
            ReadyCommand ping = new ReadyCommand();
            Answer pingAns = resource.executeRequest(ping);
            if (pingAns == null || !pingAns.getResult()) {
                String errMsg = "Agent not running, or no route to agent on at " + uri;
                s_logger.debug(errMsg);
                throw new DiscoveryException(errMsg);
            }
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

        hostResourcesMap.put(hostId, resource);
        HostEnvironment env = new HostEnvironment();
        SetupCommand cmd = new SetupCommand(env);
        cmd.setNeedSetup(true);

        resource.executeRequest(cmd);
    }

    @Override
    public synchronized Answer send(Long hostId, Command cmd) throws AgentUnavailableException,
            OperationTimedoutException {
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

        if (resource == null) {
            return null;
        }

        Answer answer = resource.executeRequest(cmd);
        return answer;
    }

    @Override
    public Answer[] send(Long hostId, Commands cmds) throws AgentUnavailableException, OperationTimedoutException {
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

                ArrayList<Answer> answers = new ArrayList<Answer>(cmds.length);
                for (int i = 0; i < cmds.length; i++) {
                    Answer answer = null;
                    try {
                        if (resource != null) {
                            answer = resource.executeRequest(cmds[i]);
                            if(answer == null) {
                              s_logger.warn("Resource returned null answer!");
                                answer = new Answer(cmds[i], false, "Resource returned null answer");
                            }
                        } else {
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

        hostResourcesMap.put(hostId, resource);
        HostEnvironment env = new HostEnvironment();
        SetupCommand cmd = new SetupCommand(env);
        cmd.setNeedSetup(true);

        resource.executeRequest(cmd);
    }

    @Override
    public synchronized Answer send(Long hostId, Command cmd) throws AgentUnavailableException, OperationTimedoutException {
        ServerResource resource = hostResourcesMap.get(hostId);
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

        if (resource == null) {
            return null;
        }

        Answer answer = resource.executeRequest(cmd);
        return answer;
    }

    @Override
    public Answer[] send(Long hostId, Commands cmds) throws AgentUnavailableException, OperationTimedoutException {
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

                ArrayList<Answer> answers = new ArrayList<Answer>(cmds.length);
                for (int i = 0; i < cmds.length; i++) {
                    Answer answer = null;
                    try {
                        if (resource != null) {
                            answer = resource.executeRequest(cmds[i]);
                            if (answer == null) {
                                s_logger.warn("Resource returned null answer!");
                                answer = new Answer(cmds[i], false, "Resource returned null answer");
                            }
                        } else {
View Full Code Here

Examples of com.cloud.resource.ServerResource.executeRequest()

                ArrayList<Answer> answers = new ArrayList<Answer>(cmds.length);
                for (int i = 0; i < cmds.length; i++) {
                    Answer answer = null;
                    try {
                        if (resource != null) {
                            answer = resource.executeRequest(cmds[i]);
                        } else {
                            answer = new Answer(cmds[i], false, "Agent is disconnected");
                        }
                    } catch (Exception e) {
                        s_logger.warn(log(seq, "Exception Caught while executing command"), e);
View Full Code Here

Examples of com.cloudbees.api.BeesClient.executeRequest()

    public JSONObject getMetaData(String appId) throws Exception {
        BeesClient client = beesClientFactory.get(BeesClient.class);
        Map<String, String> params = new HashMap<String, String>();
        params.put("app_id", appId);
        String url = client.getRequestURL("application.platform.metadata", params);
        String response = client.executeRequest(url);

        SAXBuilder sxb = new SAXBuilder();
        Document document = sxb.build(new StringReader(response));
        String js = document.getRootElement().getChild("message").getText();
View Full Code Here

Examples of com.esri.gpt.agp.client.AgpClient.executeRequest()

        con.appendToken(params);
        AgpProperties hdr = con.makeRequestHeaderProperties();
        AgpClient client = con.ensureClient();
        StringProvider prov = new StringProvider(params.toString(),sCType);
        StringHandler handler = new StringHandler();;
        client.executeRequest(sUrl,hdr,prov,handler);
        String sWebMapJson = handler.getContent();
       
       
        /*
        web map
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.