Greedy Cache issue

General discussion, compatibility and contributed extensions.

Moderators: satrow, Lootyhoof, Andrew Gilbertson

User avatar
gracious1
Keeps coming back
Keeps coming back
Posts: 815
Joined: Sun, 15 May 2016, 05:00
Location: unseasonably HOT upstate NY
Contact:

Greedy Cache issue

Unread postby gracious1 » Wed, 03 May 2017, 04:59

I discovered a peculiar issue in Greedy Cache. This was after some experimentation when my toolbars started unhiding themselves upon restart or the creation of a new window.

When the toolbar button is placed in the Navigation Toolbar, the Status (or Add-ons) Toolbar, or in a custom toolbar, that toolbar will misbehave. For example, if you hide the toolbar, and then restart PM, the toolbar will unhide itself. If you open a new window, the toolbar will also appear even though it was hidden in the parent window.
GreedyCacheButton2.png
GreedyCacheButton2.png (942 Bytes) Viewed 2370 times

It isn't necessary to diasble Greedy Cache; just removing the toolbar button will suffice, although this workaround means you don't get the benefit of turning the extension on and off with a single click.

(If you put the toolbar button in the Menu Toolbar, however, the issue does not occur. This is the only toolbar that appears to be unaffected.)

I was able to reproduce this in a test profile with the default theme and no other extensions enabled. I am running PM 27.3.0 (64-bit) on Ubuntu 14.04.5 .
Image“Life is what happens to us while we are making other plans.” ― Allen Saunders

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Wed, 03 May 2017, 12:00

All my add-ons that use toolbar buttons always try to unhide the toolbar they are placed in. It works this way for years and you are the first who found it inconvenient. I'm sure such behavior is correct, but I can add a hidden option to disable this for you in Greedy Cache.
Here are the add-ons I made in a spare time. That was fun!

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Wed, 03 May 2017, 14:20

JustOff wrote:I can add a hidden option to disable this for you in Greedy Cache.

Try greedy-cache-1.1.4b1-pm.xpi, the preference is extensions.greedy-cache.unhideToolbar.
Here are the add-ons I made in a spare time. That was fun!

User avatar
gracious1
Keeps coming back
Keeps coming back
Posts: 815
Joined: Sun, 15 May 2016, 05:00
Location: unseasonably HOT upstate NY
Contact:

Re: Greedy Cache issue

Unread postby gracious1 » Wed, 03 May 2017, 23:07

JustOff wrote:I can add a hidden option to disable this for you in Greedy Cache.

JustOff wrote:Try greedy-cache-1.1.4b1-pm.xpi, the preference is extensions.greedy-cache.unhideToolbar.

It works! Hooray! :clap: Thank you very much!
Image“Life is what happens to us while we are making other plans.” ― Allen Saunders

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Fri, 05 May 2017, 12:24

Greedy Cache 1.1.4 has been released.
Here are the add-ons I made in a spare time. That was fun!

Latitude
Astronaut
Astronaut
Posts: 571
Joined: Mon, 21 Mar 2016, 18:28

Re: Greedy Cache issue

Unread postby Latitude » Tue, 20 Jun 2017, 17:14

JustOff wrote:Greedy Cache 1.1.4 has been released.


JustOff, does it save & load cache from HTTPS site?

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Tue, 20 Jun 2017, 17:31

Greedy Cache does not save or load anything, it just instructs the browser to load scripts, images and styles from the browser's cache (if they are already there) without asking remote servers (both http and https) about possible changes of these resources.
Here are the add-ons I made in a spare time. That was fun!

Latitude
Astronaut
Astronaut
Posts: 571
Joined: Mon, 21 Mar 2016, 18:28

Re: Greedy Cache issue

Unread postby Latitude » Wed, 21 Jun 2017, 02:47

JustOff wrote:Greedy Cache does not save or load anything, it just instructs the browser to load scripts, images and styles from the browser's cache (if they are already there) without asking remote servers (both http and https) about possible changes of these resources.


It could save our data plan/quota, right?

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Wed, 21 Jun 2017, 10:17

The main benefit is the decrease of overall page load time, see screenshots below. But the size of data received from the network is virtually the same, regardless of the results shown by the network monitor, it simply does the wrong calculations in case of cached data.

palemoon_2017-06-21_12-43-25.png

palemoon_2017-06-21_12-44-32.png
Here are the add-ons I made in a spare time. That was fun!

User avatar
Massimo_B
Hobby Astronomer
Hobby Astronomer
Posts: 27
Joined: Fri, 06 Jan 2017, 08:30

Re: Greedy Cache issue

Unread postby Massimo_B » Thu, 22 Jun 2017, 07:19

Hi, there is only little information about that addon. Does it just always ignore max-age and cache-control for all scripts and pictures? What is the behaviour for refresh (F5) or force refresh (CTRL+F5)?
Isn't that breaking websites with real-time charts or something? After all I'm looking to improve browsing on slow mobile links.

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Thu, 22 Jun 2017, 12:03

Massimo_B wrote:Hi, there is only little information about that addon. Does it just always ignore max-age and cache-control for all scripts and pictures?

By default it does not alter neither Max-age nor Cache-control headers received from remote servers, so the browser as usual uses them to decide when to store data in the cache and how long it should be kept. Greedy Cache just sets LOAD_FROM_CACHE flag for all requests of types TYPE_SCRIPT, TYPE_IMAGE and TYPE_STYLESHEET to force the browser not to try to re-validate the cache objects if they exist.
What is the behaviour for refresh (F5) or force refresh (CTRL+F5)?

Simple refresh requests made by F5 or reload button are also not re-validated, but forced refresh requests (Ctrl+F5) ignore LOAD_FROM_CACHE flag and can still be used to load the updated data (and update the cache).
Isn't that breaking websites with real-time charts or something? After all I'm looking to improve browsing on slow mobile links.

Since all cache control directives received from remote servers are respected this will not break none of sites that properly declare their caching logic.

Aside of that Greedy Cache has an extra option that enforces the caching of images, even if servers did not ask to do so or even not allow it. This can potentially lead to some problems, but in practice this is extremely rare and I personally always turn it on.
Here are the add-ons I made in a spare time. That was fun!

User avatar
Massimo_B
Hobby Astronomer
Hobby Astronomer
Posts: 27
Joined: Fri, 06 Jan 2017, 08:30

Re: Greedy Cache issue

Unread postby Massimo_B » Thu, 22 Jun 2017, 12:11

That all sounds more like a thing that every browser core should have as option. I remember some while ago there have been options to change the cache usage behaviour which often confused people.
I think enabling Greedy Cache and all options is optimal for me as I can force refresh if I encounter issues.

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Thu, 22 Jun 2017, 12:58

Massimo_B wrote:That all sounds more like a thing that every browser core should have as option.

Actually browsers can't just change their behavior by acting in a way that's against to web standards. There is a fairly new draft that proposes to extend Cache-control header with new attribute immutable to solve this. It was already implemented by Chrome, Firefox and Safari (not by Pale Moon yet) and actively used on Facebook servers. This approach is safer, although Greedy Cache allows to save more. ;)
Here are the add-ons I made in a spare time. That was fun!

User avatar
Pale Moon Rising
Knows the dark side
Knows the dark side
Posts: 3193
Joined: Tue, 06 Oct 2015, 16:59
Location: Los Angeles CA USA

Re: Greedy Cache issue

Unread postby Pale Moon Rising » Sun, 08 Oct 2017, 16:54

What does this pref do: extensions.greedy-cache.before?

I was hoping to speed-up my start.me start-page load since it is large and takes a long time but I can't see any difference in load time with the add-on enabled compared to disabled. So I was wondering if this pref would do anything to improve on the load specifically for my start-page (most other pages there is no issue, they all load quick, the only one that takes more time than most is this one page).
Current Pale Moon(x86) Release | WIN7(64-bit) | I3 CPU, 2.53 GHz, 4G RAM

Good judgment comes from experience and a lot of that comes from bad judgment. - Will Rogers

Knowing Pale Moon is indisputably #1 is defined by knowing the totality of browsers. - Pale Moon Rising

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Sun, 08 Oct 2017, 17:54

Pale Moon Rising wrote:What does this pref do: extensions.greedy-cache.before?

It's just a service pref, please don't play with it.

Off-topic:
I was hoping to speed-up my start.me start-page load since

IMHO, start.me is crap and nothing will help with it.
Here are the add-ons I made in a spare time. That was fun!

User avatar
badnick
Lunatic
Lunatic
Posts: 270
Joined: Thu, 23 Mar 2017, 19:56

Re: Greedy Cache issue

Unread postby badnick » Sun, 08 Oct 2017, 18:47

The purpose of this addon is somehow in contradiction with what write here ("Turn off the disk cache")
https://wiki.archlinux.org/index.php/Fi ... disk_cache

User avatar
JustOff
Localization Coordinator
Localization Coordinator
Posts: 1352
Joined: Thu, 03 Sep 2015, 19:47
Location: UA
Contact:

Re: Greedy Cache issue

Unread postby JustOff » Sun, 08 Oct 2017, 18:55

badnick wrote:"Turn off the disk cache"

This is extremely questionable advice, but I'd prefer not to start this discussion here.
Here are the add-ons I made in a spare time. That was fun!

User avatar
badnick
Lunatic
Lunatic
Posts: 270
Joined: Thu, 23 Mar 2017, 19:56

Re: Greedy Cache issue

Unread postby badnick » Sun, 08 Oct 2017, 19:12

Sorry, was just an observation, I'm not expert.

User avatar
Pale Moon Rising
Knows the dark side
Knows the dark side
Posts: 3193
Joined: Tue, 06 Oct 2015, 16:59
Location: Los Angeles CA USA

Re: Greedy Cache issue

Unread postby Pale Moon Rising » Sat, 14 Oct 2017, 17:31

JustOff wrote:
Pale Moon Rising wrote:What does this pref do: extensions.greedy-cache.before?

It's just a service pref, please don't play with it.

Off-topic:
I was hoping to speed-up my start.me start-page load since

IMHO, start.me is crap and nothing will help with it.
Off-topic:
Other than the slow load the start.me start-page serves us well (my wife and I) in our case in regards to how we use the Internet as we have well over 1700+ links at my fingertips with start.me of which probably several 100 we might at some point regularly use in a weeks time. So we are willing to put up with the slow load since our start-page provides ~80%+ of what we generally access on the Internet on a weekly basis. If there is another start-page that will provide us with this many links at our fingertips incorporated within 7 scrolling pages we're willing to look at it.
Current Pale Moon(x86) Release | WIN7(64-bit) | I3 CPU, 2.53 GHz, 4G RAM

Good judgment comes from experience and a lot of that comes from bad judgment. - Will Rogers

Knowing Pale Moon is indisputably #1 is defined by knowing the totality of browsers. - Pale Moon Rising

fillerup
Lunatic
Lunatic
Posts: 260
Joined: Mon, 19 May 2014, 19:14
Location: Finland

Re: Greedy Cache issue

Unread postby fillerup » Fri, 01 Dec 2017, 11:37

is it possible to exempt certain sites from Greedy Cache? it's breaking functionality on one particular website i frequent


Return to “Browser extensions”

Who is online

Users browsing this forum: No registered users and 3 guests