Workflow Orchestrator — AEM as a Cloud Service
Purpose
This is the master entry point for all AEM Workflow tasks on Cloud Service — spanning both development (building workflows) and production support (debugging and triaging workflow issues). Read this skill first. It classifies the user's request and routes to the right sub-skill.
How to Use This Skill
- Read the user's request carefully
- Classify it using the Task Classifier table below
- Load the identified sub-skill's
SKILL.md and its references
- For development tasks, always load the
workflow-foundation references alongside the sub-skill references
- For production-support tasks, the debugging and triaging skills are self-contained
Task Classifier
Development Skills
| User Says / Asks |
Sub-Skill to Load |
| "Create a workflow model", "Add steps to a workflow", "Design an OR split", "I need a parallel review" |
workflow-model-design |
| "Implement a custom process step", "Write a WorkflowProcess", "Create a ParticipantStepChooser", "Dynamic participant" |
workflow-development |
| "Start a workflow from code", "Trigger a workflow via API", "Use Manage Publication with a workflow", "HTTP REST API to start a workflow" |
workflow-triggering |
| "Configure a launcher", "Auto-start on asset upload", "Launcher not firing", "cq:WorkflowLauncher", "Overlay an OOTB launcher" |
workflow-launchers |
| "How do workflows work?", "Explain workflow architecture" |
Load workflow-foundation references only |
Production Support Skills
| User Says / Asks |
Sub-Skill to Load |
| "Workflow is stuck", "Why isn't my workflow advancing?", "No work item", "Workflow failed", "Step shows error" |
workflow-debugging |
| "Task not in Inbox", "User can't see work item", "Permissions error on workflow" |
workflow-debugging |
| "Thread pool exhausted", "Auto-advancement not working", "Queue backlog", "Sling Jobs stuck" |
workflow-debugging |
| "Repository bloat", "Too many workflow instances", "Purge not working", "Stale workflows" |
workflow-debugging |
| "What workflow errors on host X?", "Workflow activity for the past N hours", "What should I collect?" |
workflow-triaging |
| "Classify this workflow ticket", "What Splunk query should I use?", "What logs do I need?" |
workflow-triaging |
| "Why did workflow X fail? Show me the error.", "Failure details for model Y" |
workflow-triaging |
Routing heuristic:
- Building/implementing workflows → development skills (
workflow-model-design, workflow-development, workflow-triggering, workflow-launchers)
- Deep troubleshooting (decision trees, config checks, thread analysis, remediation) →
workflow-debugging
- Incident classification (symptom → runbook, log patterns, Splunk, data gathering) →
workflow-triaging
- When both debugging and triaging apply, start with
workflow-triaging to classify, then workflow-debugging for resolution
Reference Loading Order
For every workflow task on Cloud Service, load in this order:
Step 1: Always load these foundation references
workflow-orchestrator/references/workflow-foundation/architecture-overview.md
workflow-orchestrator/references/workflow-foundation/api-reference.md
workflow-orchestrator/references/workflow-foundation/jcr-paths-reference.md
workflow-orchestrator/references/workflow-foundation/cloud-service-guardrails.md
workflow-orchestrator/references/workflow-foundation/quick-start-guide.md
Step 2: Load the sub-skill's SKILL.md
workflow-model-design/SKILL.md ← for model design tasks
workflow-development/SKILL.md ← for Java implementation tasks
workflow-triggering/SKILL.md ← for start/trigger tasks
workflow-launchers/SKILL.md ← for launcher config tasks
workflow-debugging/SKILL.md ← for production debugging tasks
workflow-triaging/SKILL.md ← for incident triage tasks
Step 3: Load the sub-skill's topic references
workflow-model-design:
workflow-model-design/references/workflow-model-design/step-types-catalog.md
workflow-model-design/references/workflow-model-design/model-xml-reference.md
workflow-model-design/references/workflow-model-design/model-design-patterns.md
workflow-development:
workflow-development/references/workflow-development/process-step-patterns.md
workflow-development/references/workflow-development/participant-step-patterns.md
workflow-development/references/workflow-development/variables-and-metadata.md
workflow-triggering:
workflow-triggering/references/workflow-triggering/triggering-mechanisms.md
workflow-triggering/references/workflow-triggering/programmatic-api.md
workflow-launchers:
workflow-launchers/references/workflow-launchers/launcher-config-reference.md
workflow-launchers/references/workflow-launchers/condition-patterns.md
workflow-debugging:
workflow-debugging/SKILL.md
workflow-debugging/reference.md
workflow-triaging:
workflow-triaging/SKILL.md
Cloud Service Production Support Constraints
| Constraint |
Detail |
| No JMX |
No retryFailedWorkItems, countStaleWorkflows, restartStaleWorkflows, purgeCompleted via JMX |
| Retry failed items |
Inbox Retry only |
| Stale detection |
Custom API/script only |
| Purge |
Purge Scheduler (OSGi config in Git) |
| Log access |
Cloud Manager → Environments → Logs (download / streaming) |
| Thread dumps |
Developer Console or support request |
| Config changes |
Code in Git + Cloud Manager pipeline deploy |
AEM Cloud Service Guardrails Summary
Before doing anything, apply these non-negotiable constraints:
| Rule |
Detail |
/libs is immutable |
Never write to /libs; use /conf/global/ or /apps/ overlays |
| Model design-time path |
/conf/global/settings/workflow/models/<id> |
| Model runtime path (for API calls) |
/var/workflow/models/<id> |
| Launcher config path |
/conf/global/settings/workflow/launcher/config/ |
| Service users |
Always use workflow-process-service sub-service; never admin credentials |
| OSGi annotations |
Use DS R6 (@Component, @Reference from org.osgi.service.component.annotations) |
| Deploy via |
Cloud Manager pipeline — no Package Manager in production |
No javax.jcr.Session.loginAdministrative |
Use ResourceResolverFactory.getServiceResourceResolver() |
Full detail: references/workflow-foundation/cloud-service-guardrails.md
Quick Architecture Recap
Author tier
│
├── Content Author
│ └── triggers via: Timeline UI / Manage Publication
│
├── Custom code (OSGi service / event handler / scheduler)
│ └── triggers via: WorkflowSession.startWorkflow()
│
└── Workflow Launcher (cq:WorkflowLauncher)
└── triggers via: JCR observation events
↓
Granite Workflow Engine
↓
Workflow Instance (/var/workflow/instances/)
↓
Steps executed as Sling Jobs:
- PROCESS step → WorkflowProcess.execute()
- PARTICIPANT step → inbox task for user/group
- DYNAMIC_PARTICIPANT → ParticipantStepChooser.getParticipant()
- OR_SPLIT → route expression evaluates to true/false
- AND_SPLIT → parallel branches, AND_JOIN waits for all
Common Task Patterns (End-to-End)
Pattern A: New custom approval workflow
- Load
workflow-model-design + workflow-development sub-skills
- Design model: START → PARTICIPANT (reviewer) → PROCESS (approve/reject logic) → END
- Implement
WorkflowProcess for the approve/reject step
- Deploy model XML to
/conf/global/settings/workflow/models/
- Deploy OSGi bundle with the process step
Pattern B: Auto-process content on upload
- Load
workflow-launchers sub-skill
- Configure a
cq:WorkflowLauncher for NODE_ADDED on the DAM path
- Point it to your workflow model at
/var/workflow/models/
- Deploy launcher config to
/conf/global/settings/workflow/launcher/config/
Pattern C: Programmatically batch-start workflows
- Load
workflow-triggering sub-skill
- Implement
WorkflowStarterService using ResourceResolverFactory + WorkflowSession
- Map sub-service
workflow-starter to workflow-process-service
- Deploy and trigger from a Sling Scheduler or Servlet
Pattern D: "Workflow errors on host X for the past 4 hours"
- Load
workflow-triaging → classify as workflow_fails_or_shows_error
- Suggest Splunk / Cloud Manager log search for
Error executing workflow step on host + time range
- If errors found, load
workflow-debugging → map to runbook, walk decision tree
- Return: symptom_id, runbook, evidence, remediation
Pattern E: "Workflow stuck — not advancing"
- Load
workflow-debugging → classify as workflow_stuck_not_progressing
- Follow decision tree: check for work item → step type → specific checks
- If thread pool suspected, guide thread dump analysis (Developer Console)
- Return: root cause, config fix (via Git), remediation steps
References in This Skill
references/workflow-foundation/architecture-overview.md
references/workflow-foundation/api-reference.md
references/workflow-foundation/jcr-paths-reference.md
references/workflow-foundation/cloud-service-guardrails.md
references/workflow-foundation/quick-start-guide.md
1---2name: workflow-orchestrator-43description: Master entry point for all AEM Workflow tasks on Cloud Service spanning development and production support4license: Apache-2.05metadata:6 source: https://skillmd.com/skills/adobe/workflow-orchestrator-47---89# Workflow Orchestrator — AEM as a Cloud Service1011## Purpose1213This is the **master entry point** for all AEM Workflow tasks on Cloud Service — spanning both **development** (building workflows) and **production support** (debugging and triaging workflow issues). Read this skill first. It classifies the user's request and routes to the right sub-skill.1415## How to Use This Skill16171. Read the user's request carefully182. Classify it using the **Task Classifier** table below193. Load the identified sub-skill's `SKILL.md` and its references204. For development tasks, always load the `workflow-foundation` references alongside the sub-skill references215. For production-support tasks, the debugging and triaging skills are self-contained2223---2425## Task Classifier2627### Development Skills2829| User Says / Asks | Sub-Skill to Load |30|---|---|31| "Create a workflow model", "Add steps to a workflow", "Design an OR split", "I need a parallel review" | `workflow-model-design` |32| "Implement a custom process step", "Write a WorkflowProcess", "Create a ParticipantStepChooser", "Dynamic participant" | `workflow-development` |33| "Start a workflow from code", "Trigger a workflow via API", "Use Manage Publication with a workflow", "HTTP REST API to start a workflow" | `workflow-triggering` |34| "Configure a launcher", "Auto-start on asset upload", "Launcher not firing", "cq:WorkflowLauncher", "Overlay an OOTB launcher" | `workflow-launchers` |35| "How do workflows work?", "Explain workflow architecture" | Load `workflow-foundation` references only |3637### Production Support Skills3839| User Says / Asks | Sub-Skill to Load |40|---|---|41| "Workflow is stuck", "Why isn't my workflow advancing?", "No work item", "Workflow failed", "Step shows error" | `workflow-debugging` |42| "Task not in Inbox", "User can't see work item", "Permissions error on workflow" | `workflow-debugging` |43| "Thread pool exhausted", "Auto-advancement not working", "Queue backlog", "Sling Jobs stuck" | `workflow-debugging` |44| "Repository bloat", "Too many workflow instances", "Purge not working", "Stale workflows" | `workflow-debugging` |45| "What workflow errors on host X?", "Workflow activity for the past N hours", "What should I collect?" | `workflow-triaging` |46| "Classify this workflow ticket", "What Splunk query should I use?", "What logs do I need?" | `workflow-triaging` |47| "Why did workflow X fail? Show me the error.", "Failure details for model Y" | `workflow-triaging` |4849**Routing heuristic:**50- Building/implementing workflows → development skills (`workflow-model-design`, `workflow-development`, `workflow-triggering`, `workflow-launchers`)51- Deep troubleshooting (decision trees, config checks, thread analysis, remediation) → `workflow-debugging`52- Incident classification (symptom → runbook, log patterns, Splunk, data gathering) → `workflow-triaging`53- When both debugging and triaging apply, start with `workflow-triaging` to classify, then `workflow-debugging` for resolution5455---5657## Reference Loading Order5859For every workflow task on Cloud Service, load in this order:6061### Step 1: Always load these foundation references6263```64workflow-orchestrator/references/workflow-foundation/architecture-overview.md65workflow-orchestrator/references/workflow-foundation/api-reference.md66workflow-orchestrator/references/workflow-foundation/jcr-paths-reference.md67workflow-orchestrator/references/workflow-foundation/cloud-service-guardrails.md68workflow-orchestrator/references/workflow-foundation/quick-start-guide.md69```7071### Step 2: Load the sub-skill's SKILL.md7273```74workflow-model-design/SKILL.md ← for model design tasks75workflow-development/SKILL.md ← for Java implementation tasks76workflow-triggering/SKILL.md ← for start/trigger tasks77workflow-launchers/SKILL.md ← for launcher config tasks78workflow-debugging/SKILL.md ← for production debugging tasks79workflow-triaging/SKILL.md ← for incident triage tasks80```8182### Step 3: Load the sub-skill's topic references8384**workflow-model-design:**85```86workflow-model-design/references/workflow-model-design/step-types-catalog.md87workflow-model-design/references/workflow-model-design/model-xml-reference.md88workflow-model-design/references/workflow-model-design/model-design-patterns.md89```9091**workflow-development:**92```93workflow-development/references/workflow-development/process-step-patterns.md94workflow-development/references/workflow-development/participant-step-patterns.md95workflow-development/references/workflow-development/variables-and-metadata.md96```9798**workflow-triggering:**99```100workflow-triggering/references/workflow-triggering/triggering-mechanisms.md101workflow-triggering/references/workflow-triggering/programmatic-api.md102```103104**workflow-launchers:**105```106workflow-launchers/references/workflow-launchers/launcher-config-reference.md107workflow-launchers/references/workflow-launchers/condition-patterns.md108```109110**workflow-debugging:**111```112workflow-debugging/SKILL.md113workflow-debugging/reference.md114```115116**workflow-triaging:**117```118workflow-triaging/SKILL.md119```120121---122123## Cloud Service Production Support Constraints124125| Constraint | Detail |126|---|---|127| No JMX | No `retryFailedWorkItems`, `countStaleWorkflows`, `restartStaleWorkflows`, `purgeCompleted` via JMX |128| Retry failed items | Inbox Retry only |129| Stale detection | Custom API/script only |130| Purge | Purge Scheduler (OSGi config in Git) |131| Log access | Cloud Manager → Environments → Logs (download / streaming) |132| Thread dumps | Developer Console or support request |133| Config changes | Code in Git + Cloud Manager pipeline deploy |134135---136137## AEM Cloud Service Guardrails Summary138139Before doing anything, apply these non-negotiable constraints:140141| Rule | Detail |142|---|---|143| `/libs` is immutable | Never write to `/libs`; use `/conf/global/` or `/apps/` overlays |144| Model design-time path | `/conf/global/settings/workflow/models/<id>` |145| Model runtime path (for API calls) | `/var/workflow/models/<id>` |146| Launcher config path | `/conf/global/settings/workflow/launcher/config/` |147| Service users | Always use `workflow-process-service` sub-service; never admin credentials |148| OSGi annotations | Use DS R6 (`@Component`, `@Reference` from `org.osgi.service.component.annotations`) |149| Deploy via | Cloud Manager pipeline — no Package Manager in production |150| No `javax.jcr.Session.loginAdministrative` | Use `ResourceResolverFactory.getServiceResourceResolver()` |151152Full detail: `references/workflow-foundation/cloud-service-guardrails.md`153154---155156## Quick Architecture Recap157158```159Author tier160 │161 ├── Content Author162 │ └── triggers via: Timeline UI / Manage Publication163 │164 ├── Custom code (OSGi service / event handler / scheduler)165 │ └── triggers via: WorkflowSession.startWorkflow()166 │167 └── Workflow Launcher (cq:WorkflowLauncher)168 └── triggers via: JCR observation events169 ↓170 Granite Workflow Engine171 ↓172 Workflow Instance (/var/workflow/instances/)173 ↓174 Steps executed as Sling Jobs:175 - PROCESS step → WorkflowProcess.execute()176 - PARTICIPANT step → inbox task for user/group177 - DYNAMIC_PARTICIPANT → ParticipantStepChooser.getParticipant()178 - OR_SPLIT → route expression evaluates to true/false179 - AND_SPLIT → parallel branches, AND_JOIN waits for all180```181182---183184## Common Task Patterns (End-to-End)185186### Pattern A: New custom approval workflow1871881. Load `workflow-model-design` + `workflow-development` sub-skills1892. Design model: START → PARTICIPANT (reviewer) → PROCESS (approve/reject logic) → END1903. Implement `WorkflowProcess` for the approve/reject step1914. Deploy model XML to `/conf/global/settings/workflow/models/`1925. Deploy OSGi bundle with the process step193194### Pattern B: Auto-process content on upload1951961. Load `workflow-launchers` sub-skill1972. Configure a `cq:WorkflowLauncher` for `NODE_ADDED` on the DAM path1983. Point it to your workflow model at `/var/workflow/models/`1994. Deploy launcher config to `/conf/global/settings/workflow/launcher/config/`200201### Pattern C: Programmatically batch-start workflows2022031. Load `workflow-triggering` sub-skill2042. Implement `WorkflowStarterService` using `ResourceResolverFactory` + `WorkflowSession`2053. Map sub-service `workflow-starter` to `workflow-process-service`2064. Deploy and trigger from a Sling Scheduler or Servlet207208### Pattern D: "Workflow errors on host X for the past 4 hours"2092101. Load `workflow-triaging` → classify as `workflow_fails_or_shows_error`2112. Suggest Splunk / Cloud Manager log search for `Error executing workflow step` on host + time range2123. If errors found, load `workflow-debugging` → map to runbook, walk decision tree2134. Return: symptom_id, runbook, evidence, remediation214215### Pattern E: "Workflow stuck — not advancing"2162171. Load `workflow-debugging` → classify as `workflow_stuck_not_progressing`2182. Follow decision tree: check for work item → step type → specific checks2193. If thread pool suspected, guide thread dump analysis (Developer Console)2204. Return: root cause, config fix (via Git), remediation steps221222---223224## References in This Skill225226```227references/workflow-foundation/architecture-overview.md228references/workflow-foundation/api-reference.md229references/workflow-foundation/jcr-paths-reference.md230references/workflow-foundation/cloud-service-guardrails.md231references/workflow-foundation/quick-start-guide.md232```