I've been trying to get the Clear Squid Cache Trigger working correctly and I'm starting to suspect there's an actual problem with the trigger, not my configuration.
Basically the trigger doesn't seem to update any dependants (like the Clear Matrix Cache Trigger does).
My test case is roughly like so:
Create an asset lister pointing at some word docs, check this works ignoring cache ( _nocache)
Create a standard page with a regular link pointing at a doc1.doc (regular link: ./?a=12345)
make all assets live, with public permission
Check the linking screen of doc1 to ensure that both show (turns out the asset lister doesn't actually create an entry into the linking screen, oh well hopefully it works anyway)
Upload a new version of the word doc with the name doc1asdf.doc
check squid log for recent purges
My Clear Squid Cache Trigger is set to be extremely nervous (fires off on way too many events) and does fire off, three times… but that’s probably not a bug, just my config.
The major problem is it only fires off against the new url of the doc itself:
niether asset listers pointing at the doc or standard pages with links pointing directly at the asset id have been purged from squid cache meaning both are now out of date (this is the really important one from my point of view)
[b][/b] if the word doc was actually cached in the first place, there are now two urls that get to the doc and both of them are most likely different (otherwise I wouldn’t have been updating it would i?)
* our __data directory is actually exculded from our squid cache but we can’t disable it from getting purged (not a big deal, but it’s annoying overhead)
Any suggestions?
Should I log a bug report for this (I did look at the bugs database and couldn’t find a similar one)?
Clearing Squid cache only clears the cache of the URLs for that asset. It will not try and work out where else the asset might be displayed and clear those URLs because that would take a very very long time to try and figure out.
Instead, if you know an asset listing is listing word docs from a folder, add a trigger action that fires on asset updated for assets under that folder and clear the cache for the updated asset AND the asset listing.
You need to add those specific rules into your system for as many places as you want.
Also bear in mind that, when you set asset listing to list the doc, and create a link (./?a=xxx) to the doc in the standard page, you are creating notice links. So, they are not dependant of the doc assets.
Good point. Another thing to note is that the asset listing is probably pointed at a fodler of docs. The folder will have an entry on its Linking screen showing the link between it and the asset listing, but each individual child (word doc) will not.
[quote]Instead, if you know an asset listing is listing word docs from a folder, add a trigger action that fires on asset updated for assets under that folder and clear the cache for the updated asset AND the asset listing.[/quote]I don't think that's possible with our install (3.14.2, all SSV packages) as the Clear Squid Cache trigger doesn't have an option for which assets to update, infact there are no config options for it, only at the global preferences level, which also has nothing relevant.
The Clear Matrix Cache trigger does have those sorts of options and it would be great to see them implemented in the Clear Squid trigger.
[quote]Also bear in mind that, when you set asset listing to list the doc, and create a link (./?a=xxx) to the doc in the standard page, you are creating notice links. So, they are not dependant of the doc assets.[/quote]If that's not a dependant, what's the difference between a dependant and a child when you select those options on the Clear Matrix Cache trigger?
Well if there is an indexed link from the word doc to the folder that owns it and from the folder that owns it to the asset lister, that would suggest to me that the overhead of finding that asset lister should be fairly minimal right? At least a lot lower than waiting for a cache expiry or a user calling up and asking why something is wrong.
[quote]I don't think that's possible with our install (3.14.2, all SSV packages) as the Clear Squid Cache trigger doesn't have an option for which assets to update, infact there are no config options for it, only at the global preferences level, which also has nothing relevant.
The Clear Matrix Cache trigger does have those sorts of options and it would be great to see them implemented in the Clear Squid trigger.[/quote]
Sorry, I was thinking of the internal Matrix one, as you say. Further development of the Squid trigger action would be required.
[quote]If that's not a dependant, what's the difference between a dependant and a child when you select those options on the Clear Matrix Cache trigger?[/quote]
Dependant assets are those that are required for the main asset to function correctly. So a bodycopy is dependantly linked to a page because the page requires that bodycopy to print its contents. Dependants rarely have their own URLs, but some do, like the Multiple Page asset.