LogoLogo
Connectors
Salesforce B2B Commerce App 1.0
Salesforce B2B Commerce App 1.0
  • Salesforce B2B Commerce App 1.0
  • Introduction
    • How it works
    • What's new in version 1.0
    • Requirements
    • Before you begin
    • Enabling Digital River fulfillments
  • Integrating the Digital River Salesforce B2B Commerce App
    • Step 1: Install the Salesforce B2B Commerce App
    • Step 2: Configure the Salesforce B2B Commerce App
    • Step 3: Add custom Salesforce B2B Commerce App fields to page layouts
    • Step 4: Enable email deliverability
    • Step 5: Import ECCN codes, tax groups, and tax types
    • Step 6. Update the Product Sync settings
    • Step 7: Create a new sharing set
    • Step 8: Set up Digital River fulfillments
    • Step 9: Create page labels
    • Step 10: Create service overrides
    • Step 11: Configure CC Admin settings
    • Step 12: Refresh the configuration cache
    • Step 13: Schedule backend jobs
    • Step 14: Manage permission sets
    • Step 15. Test the Salesforce B2B Commerce App Configuration
  • Support
  • Error log
  • Version number
Powered by GitBook
On this page
  1. Integrating the Digital River Salesforce B2B Commerce App

Step 13: Schedule backend jobs

Learn how to schedule a backend job.

PreviousStep 12: Refresh the configuration cacheNextStep 14: Manage permission sets

Last updated 4 years ago

For the App to continuously synchronize data between Salesforce and Digital River, you need to schedule several backend jobs. To schedule the backend jobs:

  1. Click Setup and select Developer Console from the dropdown list. The Developer Console opens.

  2. Click Debug and select Open Execute Anonymous Window. The Enter Apex Code dialog appears.

  3. Copy the script from the first row of the table under , paste it in the Enter Apex Code dialog, and click Execute. Repeat this step for each additional script in the table.

Backend job scripts

The following table lists the jobs that you need to schedule and the apex code that you can run to set up the jobs. You can also find these settings on the Schedule Jobs tab in the DR CC Config Settings spreadsheet.

Job Name

Script for Scheduled Job

Comments

Order Level Electronic Fulfillment Job

// EFN To run every 5 minute for(Integer i=0; i<60; i=i+5){ String cronTrigger = '0 ' + i + ' * ?'; String jobID = System.schedule('Job Send EFN every 5 minutes' + i, cronTrigger, new digitalriverb2b.DRB2B_ScheduleOrderLevelEFN()); System.debug('Scheduled Job ID: ' + jobID); }

Line Item Electronic Fulfillment Job

// Line Item EFN every 5 minutes for(Integer i=0; i<60; i=i+5){ String cronTrigger = '0 ' + i + ' * ?'; String jobID = System.schedule('Job Send Line Item EFN every 5 minutes' + i, cronTrigger, new digitalriverb2b.DRB2B_ScheduleLineItemEFN()); System.debug('Scheduled Job ID: ' + jobID); }

CC Subscription Processor Job

// Schedule CC Subscription Processor Job System.schedule('CC Subscription Procesor Job Hourly', '0 0 * ?', new digitalriverb2b.DRB2B_ScheduledSubscriptionProcess());

Only enable this script if you need to support subscriptions. Consult with the Digital River team before scheduling this Job.

DR Installment Subscription Processor Job

//Schedule Installment Subscription Processor Job every hour System.schedule('DR Installment Subscription Processor Job Hourly', '0 0 * ?', new digitalriverb2b.DRB2B_InstallmentSubscriptionProcessor());

Only enable this script if you need to support subscriptions. Consult with the Digital River team before scheduling this Job.

Backend job scripts