On this Page
Table of Contents | ||||
---|---|---|---|---|
|
Overview
The Salesforce Subscriber Snap is a Read-type Snap that provides the functionality to subscribe to Salesforce Platform and CDC events for a given standard and custom Salesforce object.
Note |
---|
Refer the Salesforce Platform Event Allocations and Subscribe to change events documents before configuring this Snap. |
Supported Salesforce Events
- Platform events: User-defined read/write events. These events end with "_e".
- CDC events: Read-only events created when the Salesforce objects (standard or custom) change. These events end with "ChangeEvent" or "_ChangeEvent".
Input and Output
Expected input: A stream of documents that contain data to be published on a Salesforce object
Expected output: A stream of documents with Map data that contain the individual records published on the given Salesforce object and/or original
fields.
Expected upstream Snaps: Any Snap with a document output view. For example, JSON Parser, Mapper.
Expected downstream Snaps: Any Snap with a document input view. For example, JSON Formatter, Mapper.
Prerequisites
- Ensure that Change Data Capture is enabled for the target entities. To do so login to your Salesforce instance and go to Setup → Build → Develop → Change Data Capture.
- Ensure that Field Tracking is enabled for the selected entities.
- Account must have valid access permissions.
Configuring Accounts
This Snap uses account references created on the Accounts page of SnapLogic Manager to handle access to this endpoint. See Salesforce Account for information on setting up this type of account.
Configuring Views
Input
This Snap has at most one input view.
Limitations and Known Issues
- For a Salesforce (Platform Events) Subscriber Snap, retry attempts are not logged, and currently retries are attempted only for authentication errors.
- Salesforce imposes a limit on the number of subscriptions. See Change Data Capture Allocations for details.
- Supports only Platform and CDC events.
This Snap might duplicate error documents for a single input when the Snap configuration is invalid. For example, invalid Snap settings (Replay ID or Events) or a non-existent event.
Support for Ultra Pipelines
Works in Ultra Pipelines.
Snap Input and Output
Input/Output | Type of View | Number of Views | Examples of Upstream and Downstream Snaps | Description |
---|---|---|---|---|
Input | Document | Min:0 |
| A stream of documents that contain data to be published on a Salesforce object |
Output | Document | Min:1 Max:1 |
| A stream of documents with Map data that contain the individual records published on the given Salesforce object and/or original fields. |
Snap Settings
Field | Field Type | Description | ||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
Label | Required.* | String | Specify the name for the Snap. You can modify this to be more specific, especially if you have more than one of the same Snap in your Pipeline. | |||||||||||
Service version | Required.The versionVersion* | String/Expression | Specify the version number of the Salesforce service that you want to connect to.
ExampleDefault value: 44.00 | |||||||||||
Events | Required. The* | String/Expression | The Salesforce Platform Event or CDC Event. This is a suggestible field that lists the Platform Events and CDC events available to you. Example:
Default value:None | |||||||||||
Replay ID | Required. T* | Integer/Expression | Specify the position of an event in the event stream. The Snap supports the following IDs:
Default value: -2 | |||||||||||
Message count | Required* | Integer/Expression | Specify the number of messages required to read and complete the Pipeline execution.
Default valueValue: -1 | |||||||||||
Pass through | If selected,Checkbox | Select this checkbox to pass the input document is passed through to the output view under the key 'original. If not selected'. If you deselect this checkbox, the input document is will not be passed and there is no "original" key in the output document. Default valueValue: Selected | ||||||||||||
Advanced properties | Configuration for Http Long Polling. For example, maxNetworkDelay, maxBufferSizeUse this field set to configure Http Long Polling. Click + to add Properties and Values | under Advanced Properties.. Enter each property and value in a separate row. | ||||||||||||
Properties | String | Enter the property. Default Value: N/A | ||||||||||||
Values | String | Enter the value for the property. Default Value: N/A | ||||||||||||
|
|
Insert excerpt | ||||||
---|---|---|---|---|---|---|
|
Example
This example Pipeline demonstrates how the Salesforce Subscriber Snap processes platform events.
The following Salesforce Subscriber Snap shows how the Snap is configured and how the Salesforce object's records are read.
You can see that the Replay ID is -2. So the Snaps reads messages from the beginning. And the Snap reads only 3 messages as the Message count is set to 3.The Snap processes the events and the output preview is as follows:
Download this Pipeline.
Downloads
Attachments | ||
---|---|---|
|
Insert excerpt | ||||||
---|---|---|---|---|---|---|
|