public class RemoteAgent extends Object implements AutoCloseable
RemoteAgentRule
.
Alternatively it can be created in try-with-resources block or handled manually.
Watch out as it does some unexpected things like removing all local agents from the server.Constructor and Description |
---|
RemoteAgent() |
RemoteAgent(BambooEnvironmentData bambooEnvironmentData) |
RemoteAgent(BambooEnvironmentData bambooEnvironmentData,
boolean startImmediately) |
Modifier and Type | Method and Description |
---|---|
void |
close() |
File |
getAgentExecutionDirectory()
Get remote agent installation directory
|
File |
getAgentHomeDirectory()
Get remote agent home directory
|
long |
getAgentId()
Get remote agent id
|
void |
restartAgent()
Restarts the agent.
|
void |
setLogsFolderName(String logsFolderName)
Set log folder name.
|
void |
startAgent()
Start remote agent if it's not started yet
|
void |
stopAgent()
Stops the remote agent
|
public RemoteAgent(BambooEnvironmentData bambooEnvironmentData) throws Exception
Exception
public RemoteAgent(BambooEnvironmentData bambooEnvironmentData, boolean startImmediately) throws Exception
Exception
public void close() throws Exception
close
in interface AutoCloseable
Exception
public void startAgent() throws Exception
Exception
public void restartAgent() throws Exception
Exception
public void setLogsFolderName(@Nullable String logsFolderName)
REMOTE_AGENT_LOGS_DIRECTORY
system property
is not empty.logsFolderName
- public File getAgentHomeDirectory()
public File getAgentExecutionDirectory()
public long getAgentId()
Copyright © 2021 Atlassian Software Systems Pty Ltd. All rights reserved.