AEM: How to monitor a replication queue

Description description

Environment

  • AEM 6.5
  • Experience Manager

Issue/Symptoms

When a publish process does not proceed as expected, a replication queue may be stuck.

Note: In most cases when a publish process does not proceed as expected, the replication queue may be stuck. Monitoring a replication queue can help you notice it quiet effectively.

Resolution resolution

You can obtain the list of contents in a replication queue by accessing the following URL.

Result:

{
metaData: {
root: "queue",
queueStatus: {
agentName: "Default Agent",
agentId: "publish",
isBlocked: false,
isPaused: false,
time: 1683837270303,
processingSince: 1683837270301,
lastProcessTime: 1683837270270,
nextRetryPeriod: -1683837270304
},
fields: `[`
"id",
"path",
"time",
"userid",
"type",
"size",
"lastProcessed",
"numProcessed"
`]`
},
queue: `[`
{
id: "2023/5/12/5/34/c80e9a48-1b7e-4e12-8775-5f733016e13e_3646",
path: "/content/we-retail/us/en/products/equipment/running/faba-running-pants",
time: 1683837231021,
userid: "admin",
type: "Deactivate",
size: 0,
lastProcessed: 0,
numProcessed: 0
},
{
id: "2023/5/12/5/34/c80e9a48-1b7e-4e12-8775-5f733016e13e_3695",
path: "/content/we-retail/ca/en/products/equipment/hiking/expedition-tech-long-sleeved-shirt",
time: 1683837231021,
userid: "admin",
type: "Deactivate",
size: 0,
lastProcessed: 0,
numProcessed: 0
}
`]`
}

It is recommended to access the URL with cURL regularly. “Path” value is a path of content. You can count the path value from the result to check the number of contents in a replication queue.

Example:
curl -u < user> :< password> “http://localhost:4502/etc/replication/agents.author/publish/jcr:content.queue.json”

recommendation-more-help
3d58f420-19b5-47a0-a122-5c9dab55ec7f