Tutorials A to Z » Blog Archives

Tag Archives: Batch Info

Mule 4 Mulesoft Tutorial

Salesforce – Job Info, Batch Info, Batch Result

Published by:

In our previous tutorial “CREATE BULK JOB SALESFORCE CONNECTOR” we covered on creating bulk jobs in salesforce via mule 4. In this tutorial to fetch the details related to the job created, like how many records/batches failed, successful records/batches and its number  or current status of the job; we will be using salesforce connector components provided by Mule.

We will be covering following salesforce connector in Mule 4:

  1. Job Info
  2. Batch Info List
  3. Batch Info
  4. Batch result stream
  5. Batch result

 

Job Info


Salesforce Job Info connector is used to get the details for a particular job that has been created in salesforce. This operation enables you to track the execution status.

Parameter

On successful execution of the “job info” below in the output:

Configuration –

Output –

 

Batch Info List


Salesforce Batch Info List connector get information about all batches in a job.

Parameter

On successful execution of the “job info” below in the output:

Configuration –

Output –

 

Batch Info


Salesforce Batch Info connector get information about a particular batch inside a job.

Parameter

Batch Info Parameter should contain Job Id and Batch Id for which details needs to be fetched.

On successful execution of the “job info” below in the output:

Configuration –
We will be sending JobId and id (batch Id) to Batch Info, to retrieve batch details.

Output –

 

Batch result


Salesforce Batch result connector get the result of the records processed inside a particular batch.

Parameter

Batch To Retrieve Parameter should contain Job Id and Batch Id for which details needs to be fetched.

On successful execution of the “job info” below in the output:

Configuration –
We will be sending JobId and id (batch Id) to Batch result, to retrieve batch result.

Output –

 

Batch Result Stream


Salesforce Batch Result Stream connector get the result of the records processed inside a particular batch. Best used when there are huge records result to be pulled.

Parameter

Batch To Retrieve Parameter should contain Job Id and Batch Id for which details needs to be fetched.
Streaming Strategy can store data in Memory with “Repeatable In Memory Stream” Config and stores data in file with “Repeatable File Store Stream”

On successful execution of the “job info” below in the output:

Configuration –
We will be sending JobId and id (batch Id) to Batch Result Stream, to retrieve batch result.

Output –

 

Download Mule Project for this tutorial

 

Official Mule 4 documentation on Jobs and Batch. Link.
Also refer to Bulk API Guide on Salesforce. Link