SitecoreDXG Documention
  • SitecoreDXG: The Documentation Experience Generator
  • Overview
    • SitecoreDXG: The Documentation Experience Generator
    • Comparison with SitecoreUML
    • CI/CD Integration
    • Helix Dependency Validation
  • Getting Started
    • Compatibility and System Requirements
    • Installing SitecoreDXG
      • General Installation
        • 1. Install the SitecoreDXG Generation Service
        • 2. Install RabbitMQ
        • 3. Install the SitecoreUML Service for Sitecore
        • 4. (Optional) Configure the Documentation Configuration Item for your Solution
        • 5. Install the Default RabbitMQ Middleman in a Custom Location
        • 6. (Optional) Integrate SitecoreDXG into your CI/CD Pipeline
      • Developer Installation
        • 1. Install the SitecoreDXG Generation Service for Developers
        • 2. Install RabbitMQ for Developers
        • 3. Install the SitecoreUML Service for Sitecore for Developers
        • 4. (Optional) Configure the Documentation Configuration Item for your Solution
        • 5. (Optional) Install the Default RabbitMQ Middleman for Developers
        • 6. (Optional) Integrate SitecoreDXG into your CI/CD Pipeline for Developers
    • Upgrading and Downgrading
    • Downloads
    • Using SitecoreDXG
      • Using the Default RabbitMQ Middleman and Trigger
        • Using the DocumentationConfiguration Object
      • Using the Provided AWS S3 Deploy Completion Handler
      • Using the Provided Azure Blob Storage Deploy Completion Handler
  • Architecture
    • Architecture Overview
    • Roles
      • Role Combinations
    • Components
    • Plugins
      • Trigger Plugins
      • Completion Handler Plugins
    • Middlemen
    • Understanding the Default RabbitMQ Middleman and Trigger
  • How To
    • CI/CD Integration
      • Integrating SitecoreDXG into your CI/CD Pipeline
      • Integrating the Default TeamCity RabbitMQ Meta-Runner
    • Creating a Custom Trigger
      • Executing Documentation Generation
      • Executing Meta-Data JSON Generation
    • Slack and Microsoft Teams Integration
      • Integrating with Slack via Webhooks
      • Integrating with Microsoft Teams via Webhooks
    • Creating a Custom Completion Handler
    • Creating a Custom Middleman
    • Viewing Helix Validation Errors
  • About the Generated Documentation
    • Overview
    • Models
      • Template Model
      • Template Field Model
      • Template Folder Model
      • Parent-Child Relationships of Models
      • Inheritance Relationship Model
      • Dependency Relationship Model
    • Views
      • Template View
      • Template Field View
      • Template Folder View
      • Parent-Child Relationship View
      • Inheritance Relationship View
      • Dependency Relationship View
    • Diagrams
      • SitecoreUML Syntax
      • Templates Diagram
      • Template Folders Diagram
      • Layer Diagrams
      • Module Diagrams
      • Module Templates Diagrams
    • Samples
Powered by GitBook
On this page
  • How to Use a Completion Handlers
  • Completion Handler Examples
  1. Architecture
  2. Plugins

Completion Handler Plugins

PreviousTrigger PluginsNextMiddlemen

Last updated 6 years ago

SitecoreDXG is meant to integrate easily with any CI/CD or end-user setup, which means that SitecoreDXG needs to support post-generation actions that should be run if the generation was successful. This is where completion handlers come in. Completion handlers run after a successful build and can be used to run any custom logic on the output that you want. They are designed to be the most easily extensible and replaceable entity in the SitecoreDXG ecosystem, so that you can make SitecoreDXG work for any use-case.

SitecoreDXG ships with two working completion handlers, and , that are ready for immediate use, as well as an example completion handler, , to help those looking to create handlers for themselves.

Because completion handler logic is generally specific to the requirements of the end-user's CD/CD architecture, no handlers are configured to be called by default for SitecoreDXG, out of the box. In other words, while SitecoreDXG does include completion handlers for deploying to an AWS S3 bucket or an Azure Blob Storage container out of the box, using one or more completion handlers is entirely optional.

See for more details on the example and how to write your own completion handlers.

How to Use a Completion Handlers

The most popular way to completion handlers is to specify the completion handlers that you want to use in the input payload of the serialized data that is passed from the middleman to the trigger. The supports passing the completion handler ID and necessary parameters as a CLI argument, and the exposes a field for doing the same.

SitecoreDXG also supports the ability to set a default handler or set of handlers to run should no handlers be specified to run in in the input payload. You can set the default handler(s) in the ./settings.js file of your SitecoreDXG Generation Service application.

Completion Handler Examples

For some ideas/examples of completion handlers, have a look at the section.

AWS S3 Deploy
Azure Blob Storage Deploy
helloWorld.js
Creating a Custom Completion Handler
default RabbitMQ middleman
TeamCity Meta-Runner
Completion Handler Ideas