---
schema_version: "1"
id: 68282b9409520ac532f441e34fe1c4bf94d54a922e0eae764339a3c944d7a615
title: Batch Framework Initialization
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/xcloud/264-0-0/os_batch_framework_initialization_55937.md
canonical_url: https://help.salesforce.com/s/articleView?id=xcloud.os_batch_framework_initialization_55937.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: aec162937918740c9b31f872640c71f310e4c75457858888734894d14ce938dc
description: The Vlocity batch framework launches the jobs that are defined in the Vlocity Scheduled Job custom object. To start the Vlocity batch framework, you must execute Apex code, which creates an instance of the framework and invokes its start method.
products:
  - Omnistudio
release: "264"
---
# Batch Framework Initialization

The Vlocity batch framework launches the jobs that are defined in the Vlocity Scheduled Job custom object. To start the Vlocity batch framework, you must execute Apex code, which creates an instance of the framework and invokes its start method.

```
VlocityBatchFramework batchFramework = new VlocityBatchFramework();
batchFramework.startBatchScheduler('<frequency>');
```

These commands create a [CronTrigger](https://developer.salesforce.com/docs/atlas.en-us.api.meta/api/sforce_api_objects_crontrigger.htm) (scheduled job) with the name VlocityScheduledJob.

The Frequency parameter specifies how often the batch framework checks for jobs to launch. To ensure that jobs are executed on the desired schedule, specify a frequency greater than or equal to that of the highest-frequency job. For example, if you have a job that is scheduled to run hourly, specify `Hourly` or `15 Minutes` for the batch framework frequency. Note that the timing of job execution is controlled entirely by the batch framework, and jobs might not be executed at precise intervals.

```
VlocityBatchFramework batchFramework = new VlocityBatchFramework();
batchFramework.startBatchScheduler('15 Minutes');
```