Forum Discussion
Stop Refresh if it Exceeds X Minutes
- 7 months ago
Hi etane ,
There is no built-in method to check/stop the refresh time of any object in fabric .
you can use either pipeline/notebook to orchestrate the entire process of refreshing and monitoring the pipelines .
Note bookapproach :Run A → wait max 30 minutes max
If completed before 30 mins → Run B
If exceeded 30 mins → cancel + notify + STOP A -> go ahead with BRun B → wait max 30 minutes max
If completed before 30 mins → Run C
If exceeded 30 mins → cancel + notify + STOP B -> go ahead with C
Run C → wait max 30 minutes max
If completed before 30 mins → notify user all process compelted
If exceeded 30 mins → cancel + notify + STOP C
Use the Rest API calls to get the dataflow run status
Also any reason for running the data flows in sequential? is there any dependency or just to limit the stress on the capacity the dataflows are ran in sequential
Thanks
Hi etane
What you could do is to look at using Power Automate to monitor the refresh of a data flow and if it exceeds a certain amount of time you could then stop it. To do this you would need to use the Power BI REST Apis.
Here is the API to get start the refresh: Dataflows - Refresh Dataflow - REST API (Power BI Power BI REST APIs) | Microsoft Learn
Here is the API to monitor the Refresh: Dataflows - Get Dataflow Transactions - REST API (Power BI Power BI REST APIs) | Microsoft Learn
And here is the API to cancel the refresh: Dataflows - Cancel Dataflow Transaction - REST API (Power BI Power BI REST APIs) | Microsoft Learn