When you create, edit, or delete a sharing rule, recalculation runs to update record access in the organization. This operation can take some time if you have many users and a lot of data. The object-specific share locks feature enables you to make changes to a sharing rule for other objects, without waiting for recalculation across all objects to complete. Depending on the object, sharing rule type, and target group of the users, you can make changes to sharing rules on another object or the same object via the UI or API.
Without object-specific share locks, you can’t submit simultaneous sharing changes until recalculation across all objects is complete. If you are enabling object-specific share locks, consider the following changes in your organization.
- Criteria-based and ownership-based sharing rules
- Recalculation is run if a sharing rule has changed or when you click the Recalculate button on the Sharing Settings page. Clicking this button locks sharing rules for that object (1), but you can still make changes to sharing rules for another object.
- When an ownership-based sharing recalculation is in progress, you can’t create, edit, or delete ownership-based sharing rules for an object that targets the affected group of users. For example, let’s say you’re creating an ownership-based lead sharing rule targeting all internal users. You can create, update, or delete another ownership-based sharing rules for leads targeting all internal users only after the recalculation finishes. You’ll receive an email notification when the recalculation is complete. However, you can still create another ownership-based sharing rules for leads targeting any other public group except the All Internal Users group, while the recalculation from the creation of the first sharing rule is still in progress.
- When a criteria-based sharing recalculation is in progress, you can’t edit or delete that rule (2). But you can simultaneously create, edit, or delete any other criteria-based or ownership-based sharing rule.
- You can’t modify the organization-wide defaults when a recalculation is running and vice versa.
- Account, cases, contacts, and opportunities
- Sharing rules can affect accounts and the associated account children—cases, contacts, and opportunities, so they are locked together to ensure that recalculation runs properly. For example, creating and editing account sharing rules prevents you from creating or editing a case, contact, or opportunity sharing rule. Similarly, creating or editing an opportunity sharing rule prevents you from creating or editing a case, contact, or account sharing rule before recalculation is complete. Note that locks are not shared across objects, except in the case of accounts and associated account children.
- In the following example, an ownership-based account sharing rule has been deleted and recalculation is in progress. Although you can’t create, edit, or delete another ownership-based sharing rule belonging to any of these objects, you can make changes to a criteria-based sharing rule (3) belonging to those objects.