Examples of AgentNotSupportedException


Examples of org.rhq.core.clientapi.server.core.AgentNotSupportedException

        // fail-fast if we can't even support this agent
        if (!getAgentManager().isAgentVersionSupported(request.getAgentVersion()).isSupported()) {
            log.warn("Agent [" + request.getName() + "][" + request.getAddress() + ':' + request.getPort() + "]["
                + request.getAgentVersion() + "] would like to register with this server but it is not supported");
            throw new AgentNotSupportedException("Agent [" + request.getName() + "] is an unsupported agent: "
                + request.getAgentVersion());
        }

        // Make a very quick test to verify the agent's remote endpoint can be connected to.
        // If not, no point in continuing - the server won't be able to talk to the agent anyway.
View Full Code Here

Examples of org.rhq.core.clientapi.server.core.AgentNotSupportedException

        AgentVersionCheckResults agentVersionCheckResults = getAgentManager().isAgentVersionSupported(agentVersion);
        if (!agentVersionCheckResults.isSupported()) {
            log.warn("Agent [" + agentName + "][" + agentVersion
                + "] would like to connect to this server but it is not supported");
            throw new AgentNotSupportedException("Agent [" + agentName + "] is an unsupported agent: " + agentVersion);
        }

        Agent agent = getAgentManager().getAgentByName(agentName);
        if (agent == null) {
            throw new AgentRegistrationException("Agent [" + agentName + "] is not registered");
View Full Code Here

Examples of org.rhq.core.clientapi.server.core.AgentNotSupportedException

                if (agentUpdateEnabled) {
                    AgentVersion latestVersion = results.getLatestAgentVersion();
                    if (latestVersion != null && latestVersion.getBuild() != null) {
                        AgentVersion ourVersion = getAgentVersion();
                        if (!ourVersion.getBuild().equals(latestVersion.getBuild())) {
                            throw new AgentNotSupportedException(MSG.getMsg(
                                AgentI18NResourceKeys.AGENT_BUILD_DOES_NOT_MATCH_AUTO_UPDATE_NOW, ourVersion,
                                latestVersion));
                        }
                    }
                }
View Full Code Here

Examples of org.rhq.core.clientapi.server.core.AgentNotSupportedException

                Thread.currentThread().interrupt();
            }

            // if this agent was never registered because it is needs to be updated, break the loop immediately
            if (AgentUpdateThread.isUpdatingNow()) {
                throw new AgentNotSupportedException();
            }

            // keep doubling the sleep time so we gradually wait longer and longer - up to 60 seconds max
            sleep_time *= 2L;
            if (sleep_time > 60000L) {
View Full Code Here

Examples of org.rhq.core.clientapi.server.core.AgentNotSupportedException

            sender_to_server.addStateListener(listener, true);
            try {
                zero = latch.await(wait_ms, TimeUnit.MILLISECONDS);
                // if this agent is updating, break the loop immediately by throwing exception
                if (AgentUpdateThread.isUpdatingNow()) {
                    throw new AgentNotSupportedException();
                }
            } catch (InterruptedException e) {
                Thread.currentThread().interrupt();
            } finally {
                sender_to_server.removeStateListener(listener);
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.