Welcome Guest Search | Active Topics | Sign In | Register

EOBrowser Cache problem Options
Eurice
Posted: Tuesday, December 8, 2020 7:26:56 AM
Rank: Advanced Member
Groups: Member

Joined: 12/10/2014
Posts: 133
Hello,

After updating several clients, I noticed an increased bandwidth use.

I saw in my logs that all EOBrowser user's were re-downloading every css and js files at every navigation : nothing was cached.

For some clients the size of their IIS request log files has been tripled; with a very big increase of css/js request.


I then checked with the lastest tabbedBrowser (20.3.34) with https://stackoverflow.com/ and again many files were either :

- not cached at all
- cached in "memory cache" but only for a few minutes
- never cached in the "disk cache" as google chrome is



Have you any information on this ?


Regards

eo_support
Posted: Tuesday, December 8, 2020 9:51:21 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Hi,

This shouldn't have anything to do with EO.WebBrowser. Cache is controlled by many factors, for example, you can set your cache policy on the server which would affect the cache related header entries in the HTTP response that would tell what cache policy the client uses. Certain requests such as HTTP POST are also never cached. So you should check on those instead.

Thanks!
Eurice
Posted: Tuesday, December 8, 2020 10:01:16 AM
Rank: Advanced Member
Groups: Member

Joined: 12/10/2014
Posts: 133
Hello,

What you describe is the reason why I tryed on a 3rd party website : stackoverflow.

Stackoverflow is sending the correct header to cache js and css files; you can test that in less than a minute.

Using chrome the files are correctly cached in the hard drive.
Using EO the files are not cached in the hard drive.

Regards
eo_support
Posted: Tuesday, December 8, 2020 4:34:42 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Hi,

I am sorry that we missed that part. How do you see which item is cached in memory and which item is cached to disk? For EO.WebBrowser the disk cache is in your temp folder and every version uses a different folder.

Thanks!
Eurice
Posted: Wednesday, December 9, 2020 2:31:12 AM
Rank: Advanced Member
Groups: Member

Joined: 12/10/2014
Posts: 133
Hello,

In order to see wich cache is used you have to check in the network tab of the debugger.
As we are testing how files load, the best is to have a debugger ready before we start the navigation.

You can do this to test :

- Start tabbed browser, open 2 tabs
- in the first tab open the remote debugging page (localhost:1234 by default)
- open the debugger for the empty tab represented by "data:text;base64...."
- make sure in the network tab that "disable cache" is not ticked
- then navigate this empty tab to stackoverflow.com
- hit f5 inside debugger to reload the stackoverflow webview

You'll see some of js/css files are cached into memory if you reload the page.
But if you close and reopen the webview (or navigate it elsewhere); all files will be downloaded again.

Do the same test with Chrome (or any browser) and you will see all the js/css files are correctly cached and not loaded from the network again.



My software is using a different cachePath and clean the cache at startup; but it was never a problem, I checked the read/write access to this folder.
EO.WebEngine.Engine.Default.Options.CachePath
EO.WebEngine.Engine.CleanUpCacheFolders(EO.WebEngine.CacheFolderCleanUpPolicy.AllVersions);


Regards
eo_support
Posted: Wednesday, December 9, 2020 1:17:35 PM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Hi,

We tested the TabbedBrowser here and we do not see any problems. TabbedBrowser does not have built-in support for F5 for refresh. So our test steps are slightly different. Here are our steps:

1. Delete EO.WebBrowser cache folder in temp folder. This is the equivalent of you calling CleanUpCacheFolders;
2. Start TabbedBrowser.exe, it opens one blank tab by default;
3. Go to menu -> Debug UI -> Select "Engine 1" at the top and "NewTab" at the bottom, then click "Debug" button. This opens DevTools, then switch to "Network" tab;
4. Load stackoverflow.com;

Note that all resources are loaded from the network since cache was cleared on step 1.

5. Close TabbedBrowser.exe, then repeat step 2 and step 4.

Note that most resources are loaded from disk cache now. A few items are still loaded from network due to "no-cache" header entries for those resources.

6. Click Refresh button in the toolbar

Note that all resource except for favicon are again loaded from the network.

7. Close TabbedBrowser.exe, then repeat step 2 and step 4.

The result is the same as step 5.

Can you try the same steps and see if you get the same result?

Thanks!
Eurice
Posted: Thursday, December 10, 2020 3:49:42 AM
Rank: Advanced Member
Groups: Member

Joined: 12/10/2014
Posts: 133
Hello,

I think deleting the folder made this works again, sorry for the time loss.


"TabbedBrowser does not have built-in support for F5 for refresh" => no but the debugger's does !

Thanks, regards
eo_support
Posted: Thursday, December 10, 2020 11:02:05 AM
Rank: Administration
Groups: Administration

Joined: 5/27/2007
Posts: 24,071
Eurice wrote:
"TabbedBrowser does not have built-in support for F5 for refresh" => no but the debugger's does !


Ah!!


You cannot post new topics in this forum.
You cannot reply to topics in this forum.
You cannot delete your posts in this forum.
You cannot edit your posts in this forum.
You cannot create polls in this forum.
You cannot vote in polls in this forum.