public class AgentQueueAccessorImpl extends Object implements AgentQueueAccessor
AgentQueueAccessor.QueueAccessResult| Constructor and Description |
|---|
AgentQueueAccessorImpl() |
| Modifier and Type | Method and Description |
|---|---|
CommonContext |
takeBuildContext(long id)
Takes a
CommonContext from the queue, blocking until one is available. |
AgentQueueAccessor.QueueAccessResult |
takeContext(long agentId)
Takes a
CommonContext from the queue, blocking until one is available. |
@Nullable public CommonContext takeBuildContext(long id) throws InterruptedException
AgentQueueAccessorCommonContext from the queue, blocking until one is available.
The lock on the build is not released. The caller should call com.atlassian.bamboo.build.BuildExecutionManager#finishBuild(PlanResultKey) to
release this lock when ready.
takeBuildContext in interface AgentQueueAccessorid - the id of the agent that is taking the build context.CommonContext, null in case of timeout on retrieval.InterruptedException - if the calling Thread is interrupted.public AgentQueueAccessor.QueueAccessResult takeContext(long agentId) throws InterruptedException
AgentQueueAccessorCommonContext from the queue, blocking until one is available.
The lock on the build is not released. The caller should call com.atlassian.bamboo.build.BuildExecutionManager#finishBuild(PlanResultKey) to
release this lock when ready.
takeContext in interface AgentQueueAccessoragentId - the id of the agent that is taking the build context.AgentQueueAccessor.QueueAccessResult containing: CommonContext on success, error message on error, nulls in case of timeout on retrieval.InterruptedException - if the calling Thread is interrupted.Copyright © 2021 Atlassian Software Systems Pty Ltd. All rights reserved.