Configure Apex Batch

Two type of Apex batch jobs are available:

  1. Update all phone numbers specified by the Display Configurations configured.
  2. Retry any phone numbers whose API call failed in previous attempts. The following sections provide instructions on scheduling these batch jobs.

Be Sure you have completed the Installation And Setup and Create Display Configurations guides before continuing.

Contents

Schedule Batch to Update All Phone Numbers

An Apex batch job can be configured to periodically update the phone validation data. The batch job will update all the phone validation data defined by the Display Configurations that have been configured by the system administrator.

  1. Go to Apex Classes in setup (you can search for it in the quick find box) Screenshot go to apex classes in setup
  2. Click the Schedule Apex button Screenshot go to apex classes in setup
  3. In the Apex Class text box, enter PhoneValidationBatch
  4. Configure the Frequency, Start, End, and Preferring Start Time fields Screenshot schedule apex
  5. Click the Save button
  6. Go to Scheduled Jobs in setup to view or delete the job (you can search for it in the quick find box) Screenshot scheduled jobs
  7. Go to Apex Jobs in setup to view in process and completed DisplayConfigBatch jobs (you can search for it in the quick find box). There will be one DisplayConfigBatch for each Display Configuration setup by the system administrator after the PhoneValidationBatch job is executed Screenshot apex jobs

Schedule Retry Batch Job

An Apex batch job can be configured to retry any phone number whose API called failed on a previous attempt. API call failures can occur due to network or service outages. These records are identified by the API_Call_Failed__C field on the Phone_Validation__c object.

  1. Go to Apex Classes in setup (you can search for it in the quick find box) Screenshot go to apex classes in setup
  2. Click the Schedule Apex button Screenshot go to apex classes in setup
  3. In the Apex Class text box, enter PhoneValBatchRetry
  4. Configure the Frequency, Start, End, and Preferring Start Time fields Screenshot schedule apex
  5. Click the Save button
  6. Go to Scheduled Jobs in setup to view or delete the job (you can search for it in the quick find box) Screenshot scheduled jobs
  7. Go to Apex Jobs in setup to view in process and completed RetryAPIFailedBatch jobs (you can search for it in the quick find box). There will be one RetryAPIFailedBatch for each Display Configuration setup by the system administrator after the PhoneValBatchRetry job is executed Screenshot apex jobs
Back To Top