You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@sling.apache.org by tm...@apache.org on 2020/01/30 11:03:58 UTC
[sling-org-apache-sling-distribution-core] branch master updated:
SLING-9016 Distribution Event should be generated when the package is
dropped * For SimpleDistributionAgentQueueProcessor,
the only time a package is dropped would be if a valid error strategy is
configured and retries have exceeded max-retry-attempts configured
This is an automated email from the ASF dual-hosted git repository.
tmaret pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/sling-org-apache-sling-distribution-core.git
The following commit(s) were added to refs/heads/master by this push:
new 7939b32 SLING-9016 Distribution Event should be generated when the package is dropped * For SimpleDistributionAgentQueueProcessor, the only time a package is dropped would be if a valid error strategy is configured and retries have exceeded max-retry-attempts configured
new b55c7d3 Merge pull request #36 from actinium15/issue/SLING-9016
7939b32 is described below
commit 7939b325beea240d13aada61aeca1c2b48b54089
Author: Ashish Chopra <as...@adobe.com>
AuthorDate: Thu Jan 30 16:27:53 2020 +0530
SLING-9016 Distribution Event should be generated when the package is dropped
* For SimpleDistributionAgentQueueProcessor, the only time a package is dropped would be
if a valid error strategy is configured and retries have exceeded max-retry-attempts configured
---
.../distribution/agent/impl/SimpleDistributionAgentQueueProcessor.java | 2 ++
1 file changed, 2 insertions(+)
diff --git a/src/main/java/org/apache/sling/distribution/agent/impl/SimpleDistributionAgentQueueProcessor.java b/src/main/java/org/apache/sling/distribution/agent/impl/SimpleDistributionAgentQueueProcessor.java
index 1a04fa7..925e710 100644
--- a/src/main/java/org/apache/sling/distribution/agent/impl/SimpleDistributionAgentQueueProcessor.java
+++ b/src/main/java/org/apache/sling/distribution/agent/impl/SimpleDistributionAgentQueueProcessor.java
@@ -157,6 +157,8 @@ class SimpleDistributionAgentQueueProcessor implements DistributionQueueProcesso
if (errorQueueStrategy != null && queueItemStatus.getAttempts() > retryAttempts) {
removeItemFromQueue = reEnqueuePackage(distributionPackage);
+ distributionEventFactory.generatePackageEvent(DistributionEventTopics.AGENT_PACKAGE_DROPPED,
+ DistributionComponentKind.AGENT, agentName, distributionPackage.getInfo());
distributionLog.info("[{}] PACKAGE-QUEUED {}: distribution package {} was enqueued to an error queue", queueName, requestId, distributionPackage.getId());
}
}