Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Aidenfry
Frequent Visitor

Publish to Web - 1 hour cache reduction

Hello All,

 

There is plenty of talk on there about this 1 hour caching for the publish to web feature.

but all the Threads i have seen are old so I would like to ask again if there is any way to imrpove this?

 

I have been tasked with developing a near-live website to do some basic visualisations from a database.

I've gone through lots of development to get my report nice and live using direct queries etc, only to be flumoxed at the last step.

 

I know i should have found this earlier on in my process before proceeding with powerbi and now i am loath to go back and find another visualisation tool which does this.

 

Please tell me someone knows of a clever hack around to improve the refresh rate of the iFrame to 5-10 or even 15 minutes would do.

 

I saw some thread on here suggesting to include a "&refresh=5" at the end of the url, but this doesnt seem to have worked at all.

 

Please some one save my skin and late nights...

 

Note i am on the powerBI Pro Trial, I can purchase full pro if this helps but i cant find any documentation that says it will.

 

Thanks,

Aiden

1 ACCEPTED SOLUTION

@Aidenfry It sounds like you would be much better off serving up your reports using embedded. Publish to Web is a free offering that is suitable for blogs, public marketing, etc. and doesn't have any of the bells and whistles that you get with licensing the tool. I am not aware of anyone being able to work around this.


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

View solution in original post

3 REPLIES 3
copykai
Resolver I
Resolver I

Since this is a pretty old thread it might not be relevant for the poster, but I had a similar issue and actually came up with a hack.
It wont produce live data but in my case it solved an issue with cache taking not up to but exactly 60 minutes to refresh.

You can use javascript to paramatize the iframes. In my case I have hourly updates and solved it with this code:

<html>
<head>
</head>
<body>
<iframe id = "dynamicframe" title="Random title" width="100%" height="100%" src="" frameborder="0" allowFullScreen="true"></iframe>



<script>
const hour = new Date().getHours(); 
let link;

if (hour % 2 == 0) {
 document.getElementById("dynamicframe").src="[insert link1 here]";
} else {
 document.getElementById("dynamicframe").src="[insert link2 here]";
}

</script>
</body>
</html>

 Of course you would need to setup two identical reports and datasets that has the exact same data and visuals.
But every even hour it shows report 1 and every odd hour it shows report 2.
This will simulate a cache reset every hour. If you need more refreshed you can expand it by minute, I guess.

At least it solved my issue.

@Aidenfry It sounds like you would be much better off serving up your reports using embedded. Publish to Web is a free offering that is suitable for blogs, public marketing, etc. and doesn't have any of the bells and whistles that you get with licensing the tool. I am not aware of anyone being able to work around this.


Looking for more Power BI tips, tricks & tools? Check out PowerBI.tips the site I co-own with Mike Carlo. Also, if you are near SE WI? Join our PUG Milwaukee Brew City PUG

Thank you,

 

I had come to the same conclusion.

Just running through the basic tutorials at the moment!

Thanks,

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors