---
schema_version: "1"
id: 5694b333cab42c85e9a0678972bcf3872a7eb5be758cbc5105c86266183b0ff3
title: Prevent Overlapping Field Service Optimization Requests
collection: admin
version: current
locale: en-us
portal_url: https://docs.salesforce.com/admin/current/en-us/service/264-0-0/pfs_manage_opt_conflicts_prevent_overlap.md
canonical_url: https://help.salesforce.com/s/articleView?id=service.pfs_manage_opt_conflicts_prevent_overlap.htm&release=264.0.0&type=5
source_site: help.salesforce.com
content_type: documentation
content_hash: 177a6c66084105a5e850c960c5aed8d69a8296374742728218f36b050eae71de
description: When initiating resource schedule optimization, in-day optimization, or global optimization, Field Service checks for other such optimization requests that are being processed simultaneously for the same territory or service resources with at least 1 day of overlap in the optimization horizon. For example, a dispatcher activates resource schedule optimization for a resource that’s part of a dataset being optimized through in-day optimization. If an overlap is detected, a message is shown and the newly initiated optimization request is aborted. Similarly, when a dispatcher tries to make changes to the Gantt, which is being processed by a background optimization request such as in-day optimization, a message is shown notifying the dispatcher that their changes can create unwanted results. The dispatcher can choose whether to continue with the manual changes or not.
products:
  - Field Service
release: "264"
---
# Prevent Overlapping Field Service Optimization Requests

When initiating resource schedule optimization, in-day optimization, or global optimization, Field Service checks for other such optimization requests that are being processed simultaneously for the same territory or service resources with at least 1 day of overlap in the optimization horizon. For example, a dispatcher activates resource schedule optimization for a resource that’s part of a dataset being optimized through in-day optimization. If an overlap is detected, a message is shown and the newly initiated optimization request is aborted. Similarly, when a dispatcher tries to make changes to the Gantt, which is being processed by a background optimization request such as in-day optimization, a message is shown notifying the dispatcher that their changes can create unwanted results. The dispatcher can choose whether to continue with the manual changes or not.

### Required Editions

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small edition"><colgroup><col></colgroup><tbody><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">Available in: both Salesforce Classic (not available in all orgs) and Lightning Experience</td></tr><tr class=""><td class="slds-cell-wrap" style="vertical-align:top;">The Agentforce Field Service and Operations core features, managed package, and mobile app are available in <strong>Enterprise</strong>, <strong>Unlimited</strong>, and <strong>Developer</strong> Editions.</td></tr></tbody></table>

<table class="slds-table slds-table_bordered slds-max-medium-table_stacked slds-m-bottom_small permission">
        <colgroup>
          <col style="width:50%">
          <col style="width:50%">
        </colgroup>
        <thead class="slds-text-title_caps ">
          <tr class="">
            <th scope="colgroup" class="slds-cell-wrap" colspan="2" style="text-align:center;vertical-align:top;" id="d139848e72">User
              Permissions Needed</th>
          </tr>
        </thead>
        <tbody>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d139848e72 ">To enable optimization overlaps prevention:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d139848e72 ">Custom permission set: FSL Admin Permissions</td>

          </tr>
          <tr class="">
            <td data-label="User Permissions Needed" class="slds-cell-wrap" style="vertical-align:top;" headers="d139848e72 ">To run Resource Schedule Optimization (RSO), in-day, or global
              optimization:</td>

            <td class="slds-cell-wrap" style="vertical-align:top;" headers="d139848e72 ">
              <p>One of these custom permission sets:</p>
              <ul>
                <li>Field Service Admin Permissions</li>
                <li>Field Service Dispatcher Permissions</li>
              </ul>
            </td>

          </tr>
        </tbody>
      </table>

![Package icon](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_field_service-264-0-0-production-enus/3f7dceb9-dd70-454a-b49e-bbb4526a158d/support_field_service/images/fs_package.png) _This is a Field Service managed package feature._

1. In Setup, go to Field Service Settings and verify that Field Service Enhanced Scheduling and Optimization is enabled.
2. In the Field Service Admin app, go to Field Service Settings. Select Optimization, and then select the Logic tab.
3. Verify that Enable optimization overlaps prevention is enabled (default on).

If Enable optimization overlaps prevention is selected and you try to run an optimization request while an overlapping optimization request is being processed, the new optimization request fails. An overlapping request occurs when there’s an overlap of optimized resources (caused by running on the same territory, or resource schedule optimization) and a time horizon overlap. A message is shown stating which request ID has overlapping service territories and which territories overlap, for easy troubleshooting. If the overlapping optimization request is running for a timeout period defined for the operation and isn't responding, the system aborts this request, and the new optimization request runs instead. The timeout for in-day and resource schedule optimization is 15 minutes. The timeout for global optimization is 5 hours if the optimization is in progress or queued, or 1 hour if the optimization request is new.

For [enhanced scheduled jobs](https://help.salesforce.com/s/articleView?id=service.pfs_set_up_jobs_enhanced.htm&release=264.0.0&type=5 "Optimize your team’s Field Service schedule for one or more service territories across a specified range of days. You can configure the optimization to run automatically, for example, every night or several times a day, or run it as needed."), if you try to create a scheduled job with multiple time periods that overlap for the same service territory, the parallel requests with overlapping data can conflict and result in incorrect schedules. When using Enhanced Scheduling and Optimization, ensure that Enable optimization overlaps prevention is selected in Field Service Settings (enabled by default) to avoid saving an enhanced scheduled job with overlapping time periods.

![Enhanced Schedule Jobs](https://sf-zdocs-cdn-prod.zoominsoftware.com/tdta-service-support_field_service-264-0-0-production-enus/3f7dceb9-dd70-454a-b49e-bbb4526a158d/support_field_service/images/eso_overlap_scheduled_jobs.png)

#### See Also

- [Get Ready for Field Service Scheduling and Optimization](https://help.salesforce.com/s/articleView?id=service.pfs_customization.htm&release=264.0.0&type=5 "Define your service appointment lifecycle, configure appointment booking settings, and get to know your Field Service scheduling policies, optimization settings, and sharing settings.")
- [Manage Scheduled Jobs in Field Service](https://help.salesforce.com/s/articleView?id=service.pfs_set_up_jobs_enhanced.htm&release=264.0.0&type=5 "Optimize your team’s Field Service schedule for one or more service territories across a specified range of days. You can configure the optimization to run automatically, for example, every night or several times a day, or run it as needed.")