I've just starting using this plugin with a site that I did not code or configure. I'm getting this error:

"The Proxy Cache directory contains n cache entries. This may indicate that 
auto-capture captures a script with a changing url that causes a new cache 
entry to be created on each request.

The Proxy configuration page shows a solution to capture scripts with a 
changing url using a JSON config object."

The referenced Proxy configuration page solution offers this:

JSON Proxy Config Object

JSON config objects enable advanced file based proxy configuration. JSON 
objects can be used together with simple file entry and must be placed on 
one line (no spaces are allowed).

JSON config objects must contain a target url (the url that will be 
downloaded by the proxy). Regular expression enables to match a source URL 
in the HTML, e.g. an URL with a cache busting date string (?time) or an url 
on a different host. Valid parameters are url, regex, regex-flags, cdn and 
expire (expire time in seconds).

{"regex": "^https://app\\.analytics\\.com/file\\.js\\?\\d+$", "regex-
flags":"i", "url": "https://app.analytics.com/file.js", "expire": "2592000"}

I've found an older link with someone having the same problem as me, where the developer replied like so:

"If you use auto capture to proxy any script and if the website contains a 
script with a changing url, e.g. a timestamp query string, a new cache entry 
will be created for each request causing the cache directory to fill. The 
configuration page shows a solution to capture such scripts by using a JSON 
config object."

My issue is that unfortunately I have no idea whatsoever what any of that means. I don't even know where to start with fixing it.

Can anyone tell me how to find out which script is causing this issue? Once I know what that is, any suggestions on how I work out what my specific regex should be for the JSON Proxy Config Object?

  • Can you show us your site? – kierzniak Dec 7 '17 at 7:17
  • The site is: skydivegeronimo.com.au. Can you tell from looking at the front end? – rickibarnes Dec 11 '17 at 10:17
  • When your cache is working is hard to tell which script is causing this. Can you turn it off? Your problem is that you have list of javascript files which are loaded every time your site is visiting by someone and some of this files, maybe only one, every time has different url. e.g: skydivegeronimo.com.au/script.min.js?time=1 skydivegeronimo.com.au/script.min.js?time=2 skydivegeronimo.com.au/script.min.js?time=3 You have to find out which javascript script have different url each time site is loaded (when cache is turned off). – kierzniak Dec 11 '17 at 11:51
  • OK great, thanks for that info. So am I literally just looking in the page source to see this? Sorry to sound noob but I just don't know about this stuff. – rickibarnes Dec 12 '17 at 5:33
  • Yes, this is my first guess, just looking in the page source and looking for script which change url on every request. But I'm not sure what is the cause. – kierzniak Dec 12 '17 at 11:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.