com.atlassian.bamboo.buildqueue.manager
Interface RemoteAgentManager

All Known Implementing Classes:
RemoteAgentManagerImpl

public interface RemoteAgentManager

Manages the interactions with remote agents


Method Summary
 void addRemoteAgentLogEntry(java.lang.String logEntry)
           
 void bootstrapping(java.lang.String agentHostName)
          Notifies the RemoteAgentManager that a remote agent has commenced bootstrapping.
 void bootstrappingElastic(java.lang.String agentHostName, java.lang.String instanceId)
          Notifies the RemoteAgentManager that an elastic agent has commenced bootstrapping.
 void checkOfflineAgents()
          Runs a check for offline remote agents.
 java.util.List<java.lang.String> getRemoteAgentLog()
           
 boolean isRemoteAgentFunctionEnabled()
          Checks whether the remote agent functionality is currently enabled.
 PipelineDefinition registerAgent(PipelineDefinition remoteAgentDefinition)
          Initial setup / verification of the agent.
 void setRemoteAgentFunctionEnabled(boolean remoteAgentFunctionEnabled)
          Controls whether the remote agent functionality of Bamboo is enabled.
 void start()
           
 void stopConnectors()
           
 void stopRemoteAgent(BuildAgent agent)
           
 AgentHeartBeatInfo updateRemoteAgentStatus(java.lang.Long agentId, java.util.UUID uuid, AgentStatus status, SystemInfo systemInfo)
          Updates the BuildAgent's status representing a remote agent on the local server.
 

Method Detail

registerAgent

@NotNull
PipelineDefinition registerAgent(@NotNull
                                         PipelineDefinition remoteAgentDefinition)
                                 throws BambooLicenseException
Initial setup / verification of the agent. This method may perform checking of whether the remote agent matches the current version on the server / updates etc

Parameters:
remoteAgentDefinition - - id may be -1 if the build is new
Returns:
RemoteAgentDefinition with the id filled
Throws:
BambooLicenseException

updateRemoteAgentStatus

AgentHeartBeatInfo updateRemoteAgentStatus(@NotNull
                                           java.lang.Long agentId,
                                           @Nullable
                                           java.util.UUID uuid,
                                           @NotNull
                                           AgentStatus status,
                                           @NotNull
                                           SystemInfo systemInfo)
Updates the BuildAgent's status representing a remote agent on the local server.

Parameters:
agentId - ID of the agent
uuid - UUID of the agent
status - agent status
systemInfo - agent system info
Returns:
current heart beat info

checkOfflineAgents

void checkOfflineAgents()
Runs a check for offline remote agents.


bootstrapping

void bootstrapping(java.lang.String agentHostName)

Notifies the RemoteAgentManager that a remote agent has commenced bootstrapping.

Parameters:
agentHostName - The host name or IP address of the host on which the remote agent is running. null if unknown.


bootstrappingElastic

void bootstrappingElastic(java.lang.String agentHostName,
                          @Nullable
                          java.lang.String instanceId)

Notifies the RemoteAgentManager that an elastic agent has commenced bootstrapping.

Parameters:
agentHostName - The host name or IP address of the host on which the remote agent is running. null if unknown.

instanceId - the instance the elastic agent is loading on

getRemoteAgentLog

java.util.List<java.lang.String> getRemoteAgentLog()

setRemoteAgentFunctionEnabled

void setRemoteAgentFunctionEnabled(boolean remoteAgentFunctionEnabled)
                                   throws java.lang.Exception

Controls whether the remote agent functionality of Bamboo is enabled.

Parameters:
remoteAgentFunctionEnabled - true if remote agent functionality should be enabled; false otherwise.
Throws:
java.lang.Exception - on any error

isRemoteAgentFunctionEnabled

boolean isRemoteAgentFunctionEnabled()
Checks whether the remote agent functionality is currently enabled.

Returns:
true, if remote agent functionality is enabled, false otherwise

stopRemoteAgent

void stopRemoteAgent(@NotNull
                     BuildAgent agent)

addRemoteAgentLogEntry

void addRemoteAgentLogEntry(java.lang.String logEntry)

start

void start()
           throws java.lang.Exception
Throws:
java.lang.Exception

stopConnectors

void stopConnectors()
                    throws java.lang.Exception
Throws:
java.lang.Exception


Copyright © 2012 Atlassian. All Rights Reserved.