Adapter for Salesforce 8.2 | webMethods Adapter for Salesforce Documentation | webMethods Adapter for Salesforce Installation and User’s Documentation | Adapter Services | Configuring Batch Operation Adapter Services
 
Configuring Batch Operation Adapter Services
Use the Batch Operation template to configure a service that handles a large number of records of a Salesforce object. The service performs the following operations against a batch of Salesforce object records:
*Inserts new records.
*Updates records.
*Inserts and updates records (upsert operation).
*Deletes records.
*Performs a query to find records and return field values from matching records.
The following table shows the input parameters of the adapter service that you configure.
Note:
You must specify a value either for the content or for the filePath input parameter. For information about what the content and file format should be, see the Salesforce documentation.
Input Variable
Description
content
Takes an object and maps it to actual data. The data type of the content parameter can be byte array, string, InputStream, or Reader.
filePath
String Loads the Salesforce object records from a csv file.
encoding
String Optional. Indicates the specific encoding for the data that the service passes. The default value is UTF-8.
The following table shows the output parameters of the adapter service that you configure.
Output Variable
Description
jobId
String The ID of the job created to perform the operation.
batchId
String List The ID of the batches of records for which the service returns the results from the executed operation.
Note:
The values of the jobId and batchId output variables are used as input variables of the Monitor Batch Operations service. For information about the Monitor Batch Operations service, see Configuring Monitor Batch Operations Adapter Services.
*To configure an adapter service using the Batch Operation template
1. Review the steps in Before Configuring or Managing Adapter Services.
2. Start Designer.
3. Right-click the package in which the service should be contained and select New > Adapter Service.
4. Select the parent namespace, type a name for the adapter service, and click Next.
5. Select Adapter for Salesforce as the adapter type and click Next.
6. Select the appropriate Adapter Connection Name and click Next.
7. From the list of available templates, select the Batch Operation template and click Finish.
The adapter service editor for the adapter service appears. You can select the Adapter Settings tab at any time to confirm adapter service properties such as the Adapter Name, Adapter Connection Name, and Adapter Service Template, as necessary.
8. Select the Batch Operation tab.
9. From the Salesforce Object field, select the Salesforce object on which the service will perform the required bulk operation.
10. From the Salesforce Bulk Operations field, select the type of bulk operation that you want the service to perform:
*insert
*update
*upsert
*delete
*query
11. In the Max number of rows per batch field, specify the number of rows that should be included in each batch. Any positive number is a valid value.
Note:
This field applies only for the insert, update, upsert, and delete operations. You cannot specify a value in this field when you select the query operation in the previous step.
12. If you selected the upsert bulk operation, from the ID Field Name list, select the field that you want to use to determine whether a record already exists in the Salesforce object.
At run time, pass a value for this field as input into the adapter service. If the value matches an existing record, the adapter service updates the record. If the value does not match an existing record, the adapter service inserts a new record.
Note:
If you do not specify any value at run time, the adapter service neither inserts nor updates the record.
13. Select File > Save to save the adapter service.
Note:
If you are using JVM version below 1.8, set the property wrapper.java.additional.8=-Dhttps.protocols=TLSv1.2 in the location, webMethods_directory/profiles/IS_default/configuration/wrapper.conf file. Here, 8 is a sample number. Therefore, set it to the next available number. This property should be added under Java Additional Parameters.