public class AgentsControl extends BackdoorControl<AgentsControl>
BackdoorControl.AddXsrfNoCheckTokenFilter, BackdoorControl.JsonMediaTypeFilter
ADMIN_REST_PATH, API_REST_PATH, DEFAULT_REST_PATH, rootPath
Constructor and Description |
---|
AgentsControl(BambooEnvironmentData environmentData) |
Modifier and Type | Method and Description |
---|---|
void |
approveAllAgents() |
RestAgent |
createLocalAgent()
Creates a new local agent with a random name and default configuration.
|
RestAgent |
createLocalAgent(boolean removeAfter) |
protected com.sun.jersey.api.client.WebResource |
createResource()
Creates the resource that corresponds to the root of the TestKit REST API, using the values returned by
BackdoorControl.getRestModulePath() . |
void |
dedicateAgentToDeploymentProject(long agentId,
long deploymentProjectId) |
void |
dedicateAgentToPlan(long agentId,
long planId) |
void |
deleteAgent(long agentId)
Deletes a Bamboo agent.
|
void |
deleteAllLocalAgents() |
void |
disableAllAgents() |
void |
enableAllAgents() |
void |
enableRemoteAgents(boolean enabled) |
List<RestDedicatedAgent> |
getAgentAssignments(long agentId) |
Set<Long> |
getEnabledAgentsIds() |
void |
tearDown()
Cleanup resources
|
void |
undedicateAllAgents() |
client, createResourceForPath, get, getEnvironmentData, getRestModulePath, percentEncode, ping, post, resourceRoot
public AgentsControl(@NotNull BambooEnvironmentData environmentData)
protected com.sun.jersey.api.client.WebResource createResource()
BackdoorControl
BackdoorControl.getRestModulePath()
. Note that the created WebResource
has the following properties: Content-Type: application/json
by
default (override with WebResource.type(javax.ws.rs.core.MediaType)
)BackdoorControl.createResource()
createResource
in class BackdoorControl<AgentsControl>
BackdoorControl.createResource()
,
BackdoorControl.getRestModulePath()
public RestAgent createLocalAgent()
public RestAgent createLocalAgent(boolean removeAfter)
public void tearDown()
BackdoorControl
tearDown
in class BackdoorControl<AgentsControl>
public void deleteAgent(long agentId)
public void deleteAllLocalAgents()
public void enableAllAgents()
public void approveAllAgents()
public void enableRemoteAgents(boolean enabled)
public void disableAllAgents()
public void undedicateAllAgents()
public void dedicateAgentToDeploymentProject(long agentId, long deploymentProjectId)
public void dedicateAgentToPlan(long agentId, long planId)
public List<RestDedicatedAgent> getAgentAssignments(long agentId)
Copyright © 2019 Atlassian Software Systems Pty Ltd. All rights reserved.