Object Settings

The Object Settings menu in FormulaShare Setup covers configuration which applies at an object level, and a section will be included on this page for each object with at least one rule configured. Options selected will apply to all rules sharing this object:

Screenshot of Object Settings page

 

Removal Strategy

Determines whether or not previous sharing is removed after changes are made to an object's sharing.

Options are:

  • Fully Managed, meaning sharing will be removed as well as applied by FormulaShare. If a data change is made which a rule now needs to apply different sharing, the original sharing will be removed as well as the new sharing created.
  • Create Only, meaning sharing will only ever be created on this object. If a rule needs to apply different sharing, the previous sharing will remain in place.

For example, if a Donation is shared based on a text field with the name of a role, and this name is changed from Finance_Manager_Malawi to Finance_Manager_Zambia on a record, under the Fully Managed option, access for Finance_Manager_Malawi will be removed and Finance_Manager_Zambia added. Under the the Create Only option, access to Finance_Manager_Malawi will be retained so the record will be shared with both roles.

The default option for custom objects is Fully Managed, and for standard objects it's Create Only. To understand why and to consider the implications in selecting an alternative, it's important to consider how assessment under the Fully Managed option differs for standard and custom objects:

  • For custom objects, Apex Sharing Reasons are used to help FormulaShare distinguish sharing applied by the app, and other apex and manual sharing used on the object. Each FormulaShare rule on a custom object is associated with a unique Apex Sharing Reason so that FormulaShare can identify which sharing was applied by this rule. When Fully Managed is used and records change in a way that means previously applied FormulaShare sharing is no longer valid, all invalid sharing for this sharing reason will be removed, but sharing for all other Apex Sharing Reasons and any manual sharing on the records is retained.
  • For standard objects, sharing reasons aren't available, so during assessment FormulaShare can’t be sure whether sharing on a record was applied by FormulaShare previously, applied manually or applied through another apex sharing mechanism. For this reason, when the Fully Managed option is used FormlulaShare will remove all sharing which is no longer valid for any currently active FormulaShare rules on the object. This will remove any FormulaShare sharing which is no longer valid, but will ALSO remove any apex sharing and manual sharing applied in the org in other ways. This option should only be used when an object is not shared manually, and when there is no apex sharing used on the object other than FormulaShare sharing.

 

Recursive Assessment Enterprise / Unlimited only

Recursive assessment applies to trigger and flow operations. By default, FormulaShare assessment will only be carried out once for each object processed by a trigger or flow per transaction.

Let's say FormulaShare shares account records, and code is called by a trigger on the Account object. If an account is updated, FormulaShare will assess whether any sharing needs to change as a result of this update, and will apply this if necessary. If as part of other logic in the trigger or other synchronous processes (e.g. another after update trigger or an after-save flow) the account is updated again, sharing won't be reassessed a second (or more) time during this trigger operation. This is to protect against the overhead of repeat processing of the same records, which isn't needed most of the time.

In some circumstances though, it may be necessary to allow assessment to happen more than once, and this setting allows this to be configured.

Experiment with this setting if a trigger or flow on this object calls FormlaShare, you expect some record updates may be happening through after-save automation, and it appears that sharing isn't being updated in real time.

 

Sharing Calculation Schedule Enterprise / Unlimited only

FormulaShare prompts you to schedule a full recalculation batch as part of the setup of the app. By default, this job will check whether any sharing updates are required for every object of every shared object.

For orgs with large numbers of records in shared objects, it may be preferable to configure Targeted Calculation Jobs to calculate sharing for subsets of records on a schedule.

This option controls which kind of assessment is used for each object.

Note that for an object to be selectable in a Targeted Calculation Job, it's necessary to first configure the Sharing Calculation Schedule object setting to an option which includes Targeted Calculation Jobs.