|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object com.atlassian.bamboo.plan.artifact.ArtifactSubscriptionManagerImpl
public class ArtifactSubscriptionManagerImpl
Field Summary |
---|
Fields inherited from interface com.atlassian.bamboo.plan.artifact.ArtifactSubscriptionManager |
---|
BAMBOO_ARTIFACTS_PATH_VARIABLE |
Constructor Summary | |
---|---|
ArtifactSubscriptionManagerImpl(ArtifactDefinitionManager artifactDefinitionManager,
ArtifactSubscriptionDao artifactSubscriptionDao,
ConsumedSubscriptionDao consumedSubscriptionDao,
ArtifactLinkDao artifactLinkDao,
ResultsSummaryManager resultsSummaryManager,
SecureTokenService secureTokenService)
|
Method Summary | |
---|---|
java.util.List<ArtifactSubscription> |
findCurrentSubscriptionsForPlan(Job producerJob)
Get list of subscriptions existing in a chain for given artifact |
ArtifactSubscription |
findSubscription(long id)
Get artifact definition of specified id |
java.util.List<ArtifactSubscription> |
findSubscriptionsOfPlan(Plan plan)
Get list of artifact subscriptions associated with a plan |
java.util.List<ArtifactDefinition> |
findSubscriptionsPossibleForPlan(Job job)
Get list of chain level artifacts available for specified plan |
com.google.common.collect.Multimap<ResultsSummary,ConsumedSubscription> |
getConsumedSubscriptions(ResultsSummary resultsSummary)
Returns list of ConsumedSubscription ordered by order of ResultsSummary execution. |
boolean |
isSubscriptionsValid(Job consumer,
Chain chain,
java.lang.String stageName)
Shorter for of validateSubscriptions method |
java.util.List<ArtifactSubscriptionContext> |
prepareSubscriptionContexts(ImmutableJob job,
PlanResultKey chainResultKey)
|
void |
removeArtifactSubscription(ArtifactSubscription artifactSubscription)
Remove artifact subscription. |
void |
removeArtifactSubscriptions(java.util.Collection<ArtifactSubscription> artifactSubscriptions)
Remove all artifact subscriptions in the collection. |
void |
removeArtifactSubscriptionsOfPlan(Plan plan)
Remove all artifact subscriptions for a plan |
void |
saveArtifactSubscription(ArtifactSubscription artifactSubscription)
Save artifact subscription. |
void |
saveArtifactSubscriptions(java.util.Collection<ArtifactSubscription> artifactSubscriptions)
Save all artifact definitions in a collection. |
void |
saveConsumedSubscription(ArtifactSubscriptionContext artifactSubscription,
PlanResultKey planResultKey)
Store consumed subscription. |
java.util.List<ArtifactSubscriptionSubstitutionAware> |
transformSubscriptions(java.util.List<ArtifactSubscription> subscriptions)
|
java.util.List<ArtifactSubscription> |
validateSubscribersForMovedJob(Job producer,
ChainStage destinationStage)
Validate all consumer artifact subscriptions to the artifacts produced by a Job against target stage |
java.util.List<ArtifactSubscription> |
validateSubscriptions(Job consumer,
Chain chain,
java.lang.String stageName)
Validate consumer artifact subscriptions against target chain and stage |
java.util.List<ArtifactSubscription> |
validateSubscriptionsForMovedStage(ChainStage movedStage,
int stageIndexAfterMove)
Validate all consumer artifact subscriptions possibly affected by moving of stage. |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public ArtifactSubscriptionManagerImpl(ArtifactDefinitionManager artifactDefinitionManager, ArtifactSubscriptionDao artifactSubscriptionDao, ConsumedSubscriptionDao consumedSubscriptionDao, ArtifactLinkDao artifactLinkDao, ResultsSummaryManager resultsSummaryManager, SecureTokenService secureTokenService)
Method Detail |
---|
public ArtifactSubscription findSubscription(long id)
ArtifactSubscriptionManager
findSubscription
in interface ArtifactSubscriptionManager
id
- id of artifact subscription
@NotNull public java.util.List<ArtifactSubscription> findSubscriptionsOfPlan(@NotNull Plan plan)
ArtifactSubscriptionManager
findSubscriptionsOfPlan
in interface ArtifactSubscriptionManager
plan
- plan which associated artifact subscriptions should be retrieved
public java.util.List<ArtifactSubscriptionSubstitutionAware> transformSubscriptions(@NotNull java.util.List<ArtifactSubscription> subscriptions)
transformSubscriptions
in interface ArtifactSubscriptionManager
@NotNull public java.util.List<ArtifactDefinition> findSubscriptionsPossibleForPlan(@NotNull Job job)
ArtifactSubscriptionManager
findSubscriptionsPossibleForPlan
in interface ArtifactSubscriptionManager
@NotNull public java.util.List<ArtifactSubscription> findCurrentSubscriptionsForPlan(@NotNull Job producerJob)
ArtifactSubscriptionManager
findCurrentSubscriptionsForPlan
in interface ArtifactSubscriptionManager
@NotNull public java.util.List<ArtifactSubscription> validateSubscribersForMovedJob(@NotNull Job producer, @NotNull ChainStage destinationStage)
ArtifactSubscriptionManager
validateSubscribersForMovedJob
in interface ArtifactSubscriptionManager
producer
- job being producer of the artifactsdestinationStage
- target stage
@NotNull public java.util.List<ArtifactSubscription> validateSubscriptions(@NotNull Job consumer, @NotNull Chain chain, @NotNull java.lang.String stageName)
ArtifactSubscriptionManager
validateSubscriptions
in interface ArtifactSubscriptionManager
consumer
- job being consumer of artifact definitionschain
- target chainstageName
- target stage
@NotNull public java.util.List<ArtifactSubscription> validateSubscriptionsForMovedStage(@NotNull ChainStage movedStage, int stageIndexAfterMove)
ArtifactSubscriptionManager
validateSubscriptionsForMovedStage
in interface ArtifactSubscriptionManager
movedStage
- stage being movedstageIndexAfterMove
- target stage index
public boolean isSubscriptionsValid(@NotNull Job consumer, @NotNull Chain chain, @NotNull java.lang.String stageName)
ArtifactSubscriptionManager
isSubscriptionsValid
in interface ArtifactSubscriptionManager
consumer
- job being consumer of artifact definitionschain
- target chainstageName
- target stage
@NotNull public java.util.List<ArtifactSubscriptionContext> prepareSubscriptionContexts(@NotNull ImmutableJob job, @NotNull PlanResultKey chainResultKey)
prepareSubscriptionContexts
in interface ArtifactSubscriptionManager
public void removeArtifactSubscription(@NotNull ArtifactSubscription artifactSubscription)
ArtifactSubscriptionManager
removeArtifactSubscription
in interface ArtifactSubscriptionManager
artifactSubscription
- ArtifactSubscription
to be removedpublic void removeArtifactSubscriptions(@NotNull java.util.Collection<ArtifactSubscription> artifactSubscriptions)
ArtifactSubscriptionManager
removeArtifactSubscriptions
in interface ArtifactSubscriptionManager
artifactSubscriptions
- collection of ArtifactSubscription
to be removedpublic void removeArtifactSubscriptionsOfPlan(@NotNull Plan plan)
ArtifactSubscriptionManager
removeArtifactSubscriptionsOfPlan
in interface ArtifactSubscriptionManager
public void saveArtifactSubscription(@NotNull ArtifactSubscription artifactSubscription)
ArtifactSubscriptionManager
saveArtifactSubscription
in interface ArtifactSubscriptionManager
artifactSubscription
- object to be savedpublic void saveArtifactSubscriptions(@NotNull java.util.Collection<ArtifactSubscription> artifactSubscriptions)
ArtifactSubscriptionManager
saveArtifactSubscriptions
in interface ArtifactSubscriptionManager
artifactSubscriptions
- collection of objects to be saved/updatedpublic void saveConsumedSubscription(@NotNull ArtifactSubscriptionContext artifactSubscription, @NotNull PlanResultKey planResultKey)
ArtifactSubscriptionManager
saveConsumedSubscription
in interface ArtifactSubscriptionManager
@NotNull public com.google.common.collect.Multimap<ResultsSummary,ConsumedSubscription> getConsumedSubscriptions(@NotNull ResultsSummary resultsSummary)
ArtifactSubscriptionManager
ConsumedSubscription
ordered by order of ResultsSummary
execution.
Artifacts whose producer does not exists are appended at the end, with null key.
getConsumedSubscriptions
in interface ArtifactSubscriptionManager
resultsSummary
- a job result
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |