Your workflow approach has several limitations that explain the lag:
First, dashboard refresh schedule constraints override workflow-triggered refreshes. Even though your workflow fires the refresh action, Lightning dashboards in Summer '24 have a minimum refresh interval of 60 minutes for system stability. When you trigger a refresh via workflow, it requests a refresh but that request gets throttled by the dashboard’s configured refresh schedule. If the dashboard just refreshed 10 minutes ago, your workflow-triggered refresh won’t execute until the next scheduled interval. This is by design to prevent excessive refresh load on the system.
Second, workflow rule limitations prevent true real-time dashboard updates. Workflow rules can only trigger asynchronous actions, and dashboard refreshes are processed in a background job queue. That queue has variable processing time depending on org load, number of concurrent jobs, and system resources. The 15-20 minute lag you’re seeing is the queue processing time plus the dashboard refresh execution time. You can’t bypass this queue with workflow rules.
Third, the Lightning component workaround is the correct solution for real-time updates. Instead of using workflow-triggered refreshes, implement a custom Lightning component that displays the key metrics from your dashboard. The component uses Lightning Data Service to subscribe to Opportunity record changes. When an opportunity stage changes to ‘Closed Won’, the component automatically re-queries the data and updates the display without requiring a full dashboard refresh.
Here’s the implementation approach: Create a Lightning Web Component that queries opportunities using wire adapters with refreshApex for real-time updates. Deploy this component to your executive dashboard page as a replacement for the traditional dashboard components. When opportunities update, the component detects the change through platform events and refreshes its data immediately. This gives you true real-time visibility without relying on the dashboard refresh queue.
Alternatively, if you must use standard dashboard components, switch from workflow rules to Flow with scheduled paths. Create a Flow that monitors high-value opportunity closures and triggers immediate dashboard refreshes, but also implements retry logic to handle queue delays. The Flow can check if the dashboard data updated successfully and retry the refresh if needed.
The fundamental issue is that workflow-triggered dashboard refreshes aren’t designed for real-time scenarios - they’re meant for periodic updates. For executive dashboards requiring immediate visibility into critical deals, custom Lightning components are the recommended approach in Summer '24 and beyond.
This draft is based on general Salesforce knowledge. It has not been verified against your specific version and environment. Practitioners: verify the steps and share your experience below.