Salesforce Sink

The Salesforce sink plugin is available in the Hub.

Plugin version: 1.5.0

A batch sink that inserts sObjects into Salesforce. Examples of sObjects are opportunities, contacts, accounts, leads, any custom objects, etc.

Configuration

Property

Macro Enabled?

Version Introduced

Description

Property

Macro Enabled?

Version Introduced

Description

Reference Name

No

 

Required. Used to uniquely identify this sink for lineage, annotating metadata, etc.

Use Connection (yes/no toggle)

No

1.5.0

Optional. Use an existing connection. If a connection is used, you do not need to provide the credentials.

Browse Connections

Yes

1.5.0

Optional. Name of the connection to use. Object Names information will be provided by the connection.

You also can use the following macro function: ${conn(connection-name)}.

Username

Yes

 

Required. Salesforce username.

Password

Yes

 

Required. Salesforce password.

Security Token

Yes

 

Optional. Salesforce security token. If the password does not contain the security token the plugin will append the token before authenticating with Salesforce.

Consumer Key

Yes

 

Required. Application Consumer Key. This is also known as the OAuth client ID. A Salesforce connected application must be created in order to get a consumer key.

Consumer Secret

Yes

 

Required. Application Consumer Secret. This is also known as the OAuth client secret. A Salesforce connected application must be created in order to get a client secret.

Login Url

Yes

 

Required. Salesforce OAuth2 login URL.

Default is https://login.salesforce.com/services/oauth2/token

Connection Timeout

Yes

1.4.4

Optional. Maximum time in milliseconds to wait for connection initialization before it times out.

Default is 30000 milliseconds.

Proxy URL

Yes

1.4.5

Optional. Proxy URL. Must contain a protocol, address and port.

SObject Name

Yes

 

Required. Salesforce object name to insert records into.

There are also sObjects that are not supported in the Bulk API of Salesforce. When a job is created using an object that is not supported in the Bulk API, “Entity is not supported by the Bulk API“ is thrown. These objects are also not supported by Einstein Analytics as it also uses Bulk API for querying data.

Below is a non-comprehensive list of sObjects that are not currently available in the Bulk API:

  • *Feed (e.g. AccountFeed, AssetFeed, …)

  • *Share (e.g. AccountBrandShare, ChannelProgramLevelShare, …)

  • *History (e.g. AccountHistory, ActivityHistory, …)

  • *EventRelation (e.g. AcceptedEventRelation, DeclinedEventRelation, …)

  • AggregateResult

  • AttachedContentDocument

  • CaseStatus

  • CaseTeamMember

  • CaseTeamRole

  • CaseTeamTemplate

  • CaseTeamTemplateMember

  • CaseTeamTemplateRecord

  • CombinedAttachment

  • ContentFolderItem

  • ContractStatus

  • EventWhoRelation

  • FolderedContentDocument

  • KnowledgeArticleViewStat

  • KnowledgeArticleVoteStat

  • LookedUpFromActivity

  • Name

  • NoteAndAttachment

  • OpenActivity

  • OwnedContentDocument

  • PartnerRole

  • RecentlyViewed

  • ServiceAppointmentStatus

  • SolutionStatus

  • TaskPriority

  • TaskStatus

  • TaskWhoRelation

  • UserRecordAccess

  • WorkOrderLineItemStatus

  • WorkOrderStatus

Operation

Yes

 

Required. Operation used for writing data into Salesforce.

  • Insert - adds records.

  • Upsert - upserts the records. Salesforce will decide if sObjects are the same using external ID field.

  • Update - updates existing records based on ID field.

Default is Insert.

Upsert External ID Field



Yes

 

Optional. External ID field name. It is used only if operation is upsert or update. The field specified can be either ‘Id’ or any custom field, which has external ID attribute set.

Job Concurrency Mode

Yes

1.4.4

Optional. The Salesforce job concurrency mode for the bulk job. Select one of the following options:

  • Parallel. Process batches in parallel mode. 

  • Serial. Process batches in serial mode. Processing in parallel can cause lock contention. When this is severe, the Salesforce job can fail. If you’re experiencing this issue, in the Salesforce sink, change Job Concurrency Mode to Serial and run the pipeline again. This mode guarantees that batches are processed one at a time, but can significantly increase the processing time.

Default is Parallel.

Max Records Per Batch

Yes

 

Required. Maximum number of records to include in a batch when writing to Salesforce. This value cannot be greater than 10,000.

Default is 10000.

Max Bytes Per Batch

Yes

 

Required. Maximum size in bytes of a batch of records when writing to Salesforce. This value cannot be greater than 10,000,000.

Default it 10000000.

Error Handling

Yes

 

Required. Strategy used to handle erroneous records.

  • Skip on error: Ignores erroneous records.

  • Fail on error: Fails pipeline due to erroneous record.

Default is Skip on error.

Data Type Mapping

Salesforce Data Type

CDAP Schema Data Type

Salesforce Data Type

CDAP Schema Data Type

_bool

bool

_int

int

_long

long

_double, currency, percent

double

date

date

datetime

timestamp (microseconds)

time

time (microseconds)

picklist

string

multipicklist

string

combobox

string

reference

string

base64

string

textarea

string

phone

string

id

string

url

string

email

string

encryptedstring

string

datacategorygroupreference

string

location

string

address

string

anyType

string

json

string

complexvalue

string

 

Created in 2020 by Google Inc.