Skip to main content

Process modeling

Abstract

Describes the Tenant Service process modeling in the Sitecore Data Exchange Framework.

The Tenant Service (TS) handles web requests and runs synchronization processes.

You use Sitecore items to model a process. You can build Sitecore templates to accommodate any kind of data. The Content Editor offers a rich UI for creating and editing data. By using Sitecore items, you can take advantage of Sitecore platform features such as security, versioning, workflow, and localization.

You use the following components to configure process modeling:

  • Tenant Service Endpoint

  • Pipeline Context Builder

  • Response Builder

  • Matching Condition

Note

The TS extends the Data Exchange Framework (DEF) and uses most of DEF's process modeling. The following sections only describe the extensions that come with the TS.

A Tenant Service Endpoint (TSE) represents a unit of work that is modeled using the DEF and the TS and it has an implicit connection with a DEF pipeline.

Note

If you are familiar with Sitecore, you are probably familiar with the concept of a pipeline. In Sitecore, a pipeline also models a unit of work. Conceptually, pipelines in Sitecore and pipelines in the DEF serve the same purpose. TSEs, on the other hand, are resolvers for incoming requests in order to push request data through the selected pipeline.

The main difference between Sitecore pipelines and DEF pipelines is that Sitecore pipelines are tightly coupled with Sitecore. They can only run within Sitecore.

For example, you can design a TSE to handle:

  • A CRM Contact Created request to create a Sitecore contact.

  • A Sitecore Submit Form Triggered request to create a Sitecore item.

In the DEF, Sitecore items represent the TSEs. For example, the following image shows the TSE that handles requests from the Sitecore Forms submit button:

The TSE that handles requests from the Sitecore Forms submit button

Note

The pipelines you select on the TSE items are configured in Sitecore, but they do not have to run within Sitecore. They are run within the TS that uses the pipelines from the DEF tenant.

The Pipeline Context Builder component is designed to extract request data in an appropriate format, build the pipeline context, and provide context to the data from the request.

Note

The pipeline uses the built Pipeline Context when it runs.

The Response Builder Component represents the response. When a pipeline step finishes, it keeps the result in the pipeline context. The response builder enables you to provide response data for each request.

There are two ways to run pipelines using the TS:

  • By a Tenant Service Endpoint ID.

  • By matching condition.

The TS handles incoming requests by TSE IDs or by matching conditions. If an endpoint ID is not set in the request query, the TS loops through the TSEs and finds the first endpoint that matches the conditions. This lets you run different pipelines with the same request with different data in the request header or content.

You can use the following matching conditions to find endpoints:

  • Absolute Path

  • Absolute URI

  • Header Name Value

  • QueryString

  • URI