Important
This article covers legacy Flux Capacity functionality.- If you are in the beginning stages of setting up resource management functionality in your org, or if you are already using TaskRay Resource Management features, refer to the new Resource Management documentation.
- If your organization currently uses Flux Capacity for resource management, use this article if you need to get information on Flux functionality.
This article helps a Flux Admin understand what happens while a Flux Capacity batch process is executing and why certain Flux Admin functions should be performed outside of normal business hours.
Flux Resource Batch Processing
Updates to Flux Resources and Time Away Plans in Flux Capacity have the potential to trigger massive data operations to initialize or re-calculate Flux forecast data. Processing of these operations is accomplished via queued batches to help Flux Capacity handle enterprise data volumes while operating within Salesforce's governor limits.
The following Flux Admin actions are subject to batch processing:
- Flux Resource activation
- Flux Resource settings changes, including utilization targets, business days, and team memberships
- Flux Time Away Plan changes, including adding, modifying or removing Time Away dates
Batch Audit and Error Logs
Two custom objects are used for auditing batch jobs:
- Flux Batch Apex Job
- Flux Batch Apex Error Log
These objects provide an audit trail for all batch apex jobs triggered in the Flux Capacity app.
A new “Flux Batch Apex Job” record is inserted every time Flux Capacity triggers a batch apex job to track progress and results (Executed, Error, Refreshed). This record is related to Flux Resources and Flux Time Away Plans and can be used to track changes to a Resource or Time Away Plan over time.
If errors are encountered during the processing of a batch, a “Flux Batch Apex Error Log” record is inserted. This record is related to the problematic Flux Batch Apex Job. The error log includes the error message and a stack trace for purposes of Flux Capacity Support troubleshooting and/or any potential data misconfigurations that will require Admin intervention.
Any unresolved Flux Batch Apex Job with an unresolved error will surface on the Flux Resource and Flux Time Away Plan Lightning detail pages, with instructions to resolve.
Additionally, these objects are available for reporting and Process Builder email alerts if a more structured process for monitoring is desired.
Record Locking
When batches are processing, the Flux Resource screen is locked and will display a progress bar as shown below.
This lock extends to TaskRay Tasks and TaskRay Time records that are affected by the change. This helps to ensure that underlying data is not modified while the Flux Capacity forecasting engine is processing a batch or while a batch is in-queue.
If an end-user attempts to edit a locked TaskRay Time, TaskRay Task or another record that indirectly causes a change to a locked Task (such as an Opportunity with a related Forecast Project), an error message may be thrown as shown below:
The Flux Capacity Resource assigned to this Task is currently being processed and will not allow TaskRay Tasks to be added or modified. Please wait for this Resource to finish processing or contact your Flux Capacity Admin.
For example, let’s say Marty Jefferson’s Flux Resource is edited, changing his Daily Total Utilization Target from 7 to 8 hours. All of the TaskRay Tasks owned by Marty from the date of edit forward are locked while Flux Capacity applies the utilization target change. All other Tasks in the system remain unlocked and editable while this change is processed. However, if an otherwise editable Task is modified and causes one of Marty’s Tasks to be updated (ex. based on a predecessor/dependent date change), an error could result.
Keep in mind that making updates to a Time Away Plan can affect MANY Flux Resources. Each of those Flux Resources, and their affected Tasks, may be locked while Flux Capacity applies the new capacity deductions across the forecasting engine.
Batch Timing and Recommendations
Most batch operations will execute quickly (within 1 minute), but larger data sets and/or multiple updates in succession may require batch job queueing that can take up to 15 minutes or longer in some situations.
Once the batch is complete, the Flux Resource and related Tasks are unlocked, and users can resume normal operations.