Validate_Salesforce_Realtime

Sample workflow to validate a Salesforce directory against a DirX Identity target system.

A validation workflow compares the content of the connected system with the state that DirX Identity holds for the corresponding target system. It runs in one of two modes, controlled by the mode parameter of the workflow:

  • InitialLoad - exports all accounts and groups and their relationships from the connected system and imports them into the target system subtree of the Identity Store in replace mode. Use this mode when you take a target system into operation.

  • Validation - detects deviations between the state known in DirX Identity and the state in the connected system, for example accounts or groups that were created or deleted outside of DirX Identity, and writes a message about each deviation into the "to do" field (dxrToDo) of the affected target system object.

Both modes update the dxrTSState attribute and the group member attributes of the affected target system objects.

Validate_Salesforce_Realtime is the validation workflow for connected systems of type Salesforce. It checks that the Salesforce users, contacts, accounts, profile assignments, permission-set assignments, and memberships represented in the Identity Store still match the connected system, and it re-applies changes when validation finds drift. Factory data sets dxminitialload to FALSE, so the workflow assumes that your baseline data is already in place before you start validation runs.

The workflows in this reference are delivered as factory data and are loaded into the Connectivity configuration database during the initial configuration. They are samples: use the Identity Manager to copy a workflow into your own scenario and adapt the copy. Do not change the delivered objects, because a product update can replace them.

At a Glance

Name

Validate_Salesforce_Realtime

Category

Target Realtime / Salesforce

Technology

Java-based real-time workflow

LDAP object class

dxmIDMWorkflowDefinition

Workflow type

ProvisionTS

Connected system / controller type

Salesforce

Configuration wizard

wf-Provisioning-Validate.xml

Active in the factory data

FALSE

Factory data version

8.4

Factory data path

Workflows/Default/Target Realtime/Salesforce/Validate_Salesforce_Realtime

Prerequisites

  • A connected directory of type Salesforce, with the bind profile Admin set to a Salesforce account that may read and update the users and related objects that you want to validate.

  • SSL is switched on for the TS port, so the Java-based Server must trust the certificate that is presented by the Salesforce endpoint.

  • A target system of type Salesforce in the Identity Store that is linked to that connected directory and already represents the Salesforce content that you want to validate.

  • The Java-based Server that runs the workflow must be able to reach both Salesforce and the Identity Store.

Workflow and Activities

Activity Type Component description Description Ports

error

error

provisioningActivity

Error Activity

Message

join

ProvisionTS

provisioningActivity

Join activity for the provision-to-TS workflow

event, IdentityDomain, notify, ts

Ports

Activity Port Component description Connector Connected directory Bind profile SSL

error

Message

errorPort

ErrorNotifyMailConnector

-

-

not set

join

event

notificationPort

JmsConnector

-

-

not set

join

IdentityDomain

provisioningPort

LdapConnector

Identity Store

Domain_Admin

not set

join

notify

notificationPort

NotifyMailConnector

-

-

not set

join

TS

provisioningPort

SalesforceConnector

Salesforce

Admin

TRUE

Channels

Table 1. Channels of port IdentityDomain (activity join)
Channel Description Reference type Delta type

members

Channel for members

OneToOne

SearchAttributes

SLSFaccounts

Channel for Salesforce Accounts

OneToOne

SearchAttributes

SLSFcontacts

Channel for Salesforce Contacts

OneToOne

SearchAttributes

SLSFpermissionSets(groups)

Channel for groups (Salesforce PermissionSets)

OneToOne

SearchAttributes

SLSFprofiles(groups)

Channel for groups (Salesforce Profiles)

OneToOne

SearchAttributes

SLSFusers(accounts)

Channel for accounts (Salesforce Users)

OneToOne

SearchAttributes

Table 2. Channels of port TS (activity join)
Channel Description Reference type Delta type

members

Channel for members

OneToOne

SearchAttributes

setPassword

Channel for setting a password

OneToOne

SearchAttributes

SLSFaccounts

Channel for Salesforce Accounts

OneToOne

SearchAttributes

SLSFcontacts

Channel for Salesforce Contacts

OneToOne

SearchAttributes

SLSFpermissionSets(groups)

Channel for groups (Salesforce PermissionSets)

OneToOne

SearchAttributes

SLSFprofiles(groups)

Channel for groups (Salesforce Profiles)

OneToOne

SearchAttributes

SLSFuser(accounts)

Channel for accounts (Salesforce Users)

OneToOne

SearchAttributes

Filters

Port Filter Description Sequence

TS

CryptFilter

decryption

1

Configuration Parameters

Table 3. Workflow parameters of Validate_Salesforce_Realtime
Parameter Default value

dxminitialload

FALSE

timeout

P0Y0M4DT0H0M0S

Table 4. Parameters of activity error
Parameter Default value

resourcefamily

Mail

retrylimit

3

timeout

P0Y0M1DT0H0M0S

waitbeforeretry

P0Y0M0DT2H0M0S

Table 5. Parameters of port Message (activity error)
Parameter Default value

decrypt.attribute

dxmPassword

Table 6. Parameters of activity join
Parameter Default value

resourcefamily

Salesforce

retrylimit

3

timeout

P0Y0M1DT0H0M0S

waitbeforeretry

P0Y0M0DT0H30M0S

Table 7. Parameters of port event (activity join)
Parameter Default value

appid

event

decrypt.attribute

userPassword

jmsprovidertype

MQSERIES

tgtisjmsclient

false

Table 8. Parameters of port IdentityDomain (activity join)
Parameter Default value

decrypt.attribute

userPassword

Table 9. Parameters of port notify (activity join)
Parameter Default value

decrypt.attribute

userPassword

Table 10. Parameters of port TS (activity join)
Parameter Default value

decrypt.attribute

Password

A Java-based real-time workflow runs as a permanently loaded configuration in the Java-based Server (IdS-J). It is triggered by a request or an event rather than by a schedule. Each workflow consists of activities; an activity opens one port per system it talks to, and each port uses a connector to reach that system.

Most provisioning workflows contain a join activity that performs the actual work and an error activity that receives requests which still fail after all retries and sends a notification about them. The retrylimit, waitbeforeretry and timeout parameters of an activity control how often and how long a failed request is retried before it is handed to the error activity.

The event port publishes change events over JMS, and the notify port sends e-mail notifications. Neither port is bound to a connected directory.

The join activity handles the validation request. Its IdentityDomain port reads the affected Salesforce user, account, contact, assignment, or membership from the Identity Store, and its TS port checks and updates the corresponding state in Salesforce. CryptFilter decrypts protected values before the request is sent to Salesforce.

A request that fails is retried up to 3 times (retrylimit) with 30 minutes between the attempts (waitbeforeretry). If it still fails, the error activity takes it over and sends a notification through the Message port; the workflow parameter timeout gives a request 4 days before it is discarded.

Operation

  1. Validation marks the affected Salesforce object in the target system subtree of the Identity Store.

  2. The Java-based Server passes the resulting request to the join activity of this workflow.

  3. The IdentityDomain port reads the affected entry from the Identity Store over the matching channel.

  4. The TS port checks the state in Salesforce and applies the required correction, including the setPassword channel when the request carries a password update.

  5. The result is written back into the Identity Store so that the request state reflects what happened in Salesforce.

  6. The event port publishes the change as a JMS event for applications that listen to provisioning events; the notify port sends the configured e-mail notifications.

  7. Requests that fail permanently are handed to the error activity, which reports them by e-mail.

The workflow is delivered inactive (dxmActive is FALSE). Copy it into your own scenario, connect the copy to your connected directory and activate the copy.