Re: Funky Cache

sartas wrote:

so latest plugin version on Github

No. That is URL for Sartas fork, not latest version.

Anyways the patch is a bit messy so I have to handpick the line codes from there anyway. Will take the SQLite support for sure.

Thumbs up

Re: Funky Cache

ecortens wrote:

One question though. Poking around, I noticed that it doesn't create "index.html" (or rather, index.$SUFFIX) files for subdirectories. This means the following:

http://example.com/ and http://example.com/index.html are both cache hits.

whereas:

http://example.com/about.html is a cache hit, but http://example.com/about/ is _always_ a cache miss.

Now, obviously, the easy solution is just to only use .html and not / for all your urls on your site. I wonder, is this what most people do already?

If you want bot  foo/bar and foo/bar/ to generate cache hit add something like following to your mod_rewrite rule:

  RewriteCond %{REQUEST_METHOD} ^GET$
  RewriteCond %{REQUEST_URI} (.*)/$
  RewriteCond %{DOCUMENT_ROOT}/cache/%1.html -f
  RewriteRule ^(.*)/$ /cache/$1.html [L,QSA]

Thumbs up

Re: Funky Cache

tuupola wrote:

I am the maintainer but since this is open source and free license anyone can fork. I however support only my version found under my GitHub account and not forks.

I probably phrased my question badly smile I was merely trying to figure out to where/whom the entries in the repository should point.

I've added the Funky Cache plugin in the repository. Please check it, if its not correct... let me or David know and we'll change it. smile

Edit: I've used the link for sartas's fork for now... once your master is patched to work with Wolf, let us know.

Last edited by mvdkleijn (2010-09-22 17:04)

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

Well I've just tested Funky Cache 0.3.6-dev
So far it seems to cache just fine.
The only problem is that it doesn't serve any of the cached pages,
and that completely beats the purpose of the plugin.
I hope it gets fixed soon.

Since I can't use sarta's fork (cause it needs Wolf CMS 0.7.0) i'm kind of stuck.

Last edited by Fortron (2010-10-18 23:12)

30

Re: Funky Cache

It only uses version 0.7.0? Where did you see that?
But that would make sense, as I am having trouble making the plugin work correctly (I am running latest Stable, 0.6.0)...

problems:
1. no caching seems to be happening
2. setting in settings panel do not stay (are they even being set?)
3. the .htaccess rules (specified by the plugin) give me a 500 error... I am using MODREWRITE to hide the ? in the url (works fine with the default .htaccess).. is that part of the issue? I know I'll have to combine them or something... right?
4. When manually trying to set caching on a page, when trying to save page, it says page not saved...

Last edited by avicus (2010-11-29 18:33)

Thumbs up

31

Re: Funky Cache

Hmm... I've clicked uninstall on the plugin setting page, removed the folder using ftp, then reuploaded the plugin from that git place, renamed the directory to funky_cache, installed the plugin on the settings screen, and things seem to be working great now... not sure why I was having trouble with the first install..
I also set my .htaccess correctly, based on the generated one from the funky plugin, changed the prefix it was referencing in the cached folder because it was wrong for some reason from .html to .php.
So seems I have it solved...

Thumbs up

Re: Funky Cache

hey everyone,

i'm late to the funky cache plugin party, but i really need this to work.
so i installed the plugin and got it enabled on the administration view, but i got two problems:
- no cache tab
- no settings link on the administration view
- all the subdirectories (in fact, all pages) on my website (http://musicwithsoulrecords.com/) now only show the homepage... from what i see in the cache directory the plugin is creating all the .html files correctly, but the HTML content is really always the homepage...

help?

Last edited by musicaldoctor (2011-07-30 21:26)

Re: Funky Cache

hello? anybody?

Re: Funky Cache

musicaldoctor wrote:

hey everyone,

i'm late to the funky cache plugin party, but i really need this to work.
so i installed the plugin and got it enabled on the administration view, but i got two problems:
- no cache tab
- no settings link on the administration view
- all the subdirectories (in fact, all pages) on my website (http://musicwithsoulrecords.com/) now only show the homepage... from what i see in the cache directory the plugin is creating all the .html files correctly, but the HTML content is really always the homepage...

help?

same here

Thumbs up

Re: Funky Cache

musicaldoctor wrote:

hello? anybody?

Sorry about that. I hadn't seen your post.The Funky Cache plugin was written for an older Wolf CMS version. I've got this on my list to check/update and will do so before Wolf CMS 0.8.0 comes out. Generally speaking though, I'd expect you don't need the plugin unless you have a seriously large site or extremely slow server.... smile

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

mvdkleijn wrote:

I've got this on my list to check/update and will do so before Wolf CMS 0.8.0 comes out. Generally speaking though, I'd expect you don't need the plugin unless you have a seriously large site or extremely slow server.... smile

As someone who is looking to use WolfCMS in a very large environment, it is on one hand good to know that it is on the list, but at the same time not very helpful if the cache plugin isn't working with the latest version.

If you could perhaps link to some documentation that illustrates the significant differences between the version this was written for and the latest version, I have no issues with updating this myself should we choose WolfCMS.  I would also greatly appreciate it.

Thumbs up

Re: Funky Cache

NuclearW, if you updated the cache plugin, I (and I'm sure, many others) would be very grateful.
I just registered to ask about this, and saw your post. This week I discovered Wolf and redid my small business web site in it, and was incredibly pleased at how it just gets out of the way and lets you design a site in PHP/HTML/CSS.

Thanks,

Matt

Thumbs up

Re: Funky Cache

I'm publishing an updated Funky Cache plugin this tonight or saturday morning CET time. Its already been updated by the gracious help of one of our users, I just want to check it and then I'll push it to the site.

I just want to mention though that the plugin is only necessary for high load sites, not for lower load sites since Wolf CMS performance is quite good already.

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

mvdkleijn wrote:

I'm publishing an updated Funky Cache plugin this tonight or saturday morning CET time. Its already been updated by the gracious help of one of our users, I just want to check it and then I'll push it to the site.

I just want to mention though that the plugin is only necessary for high load sites, not for lower load sites since Wolf CMS performance is quite good already.

Thanks! I'm looking forward to it. My site is small, a music site; almost all the images are <8KB .PNGs, and the rest is either text, SoundCloud embeds, or YouTube embeds. For now, on my current host, the bottleneck appears to be Compute Cycles, not bandwidth. If my site ever by some stroke of luck (fingers crossed) gets Slashdotted, I want to be ready.

Thanks again,

Matt

Thumbs up

Re: Funky Cache

If your current bottle neck is compute cycles, then Funky Cache will help somewhat but the HTTP server also uses compute cycles so its just a matter of time before that will fail too... smile

As far as I know, this caching method has never been tested in a "Slashdotted" scenario... smile So if anyone has real HIGH load experiences, please let us know!

By the way guys, I know I said (last) saturday but I'm taking a little more time to test it and improve it. It's currently only useful if you run Wolf CMS in the root of the site (which admittedly will be most of the time) but I want the plugin to support subdirectories too..

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

I'm glad to hear that progress is being made.

Please do let us know when it is ready.

Thumbs up

Re: Funky Cache

Hey guys,

I think it should be ready now. I tested it with a non-root site so if someone can test it against a root based site (http://www.example.com/) that would be great.

A number of changes were made in the backend, fixing some minor points, improving docs and improving htaccess rule generation. I also took out some weird dependencies and changed settings storage a little.

Do please give it a test and let me know how it goes. If all goes well, I'll remove the -dev tag from the version number and create a zip file for non-GitHub users.

Get it here: https://github.com/mvdkleijn/funky_cache

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

43

Re: Funky Cache

I gave this a very quick trial, Martijn. I got this result as reported up in comment #34:

...from what i see in the cache directory the plugin is creating all the .html files correctly, but the HTML content is really always the homepage...

Site is 0.7.5, in "root" (rewrite base is "/"), with URL_SUFFIX of .html. Settings are being saved, and pages (correct ones) created in /cache. But only homepage gets served. hmm

Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!

Re: Funky Cache

David, can you dump the REAL .htaccess you used and the one generated as an example by the plugin?

This is a rewrite rules problem, I just need to fine tune the ruleset..

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

45

Re: Funky Cache

Here's the .htaccess as used with Funky Cache - the bit between the comments is just a copy/paste from the code given as "example" in the embedded doc (and I used the /cache location also) (obviously I might have done something quite stupid big_smile):

#
# Setting Wolf CMS requirements
#
# On some server configurations you may need to comment out one or more of
# the three lines below due to server limitations.
#
 
# php_flag magic_quotes_gpc off
AddDefaultCharset UTF-8
Options -Indexes +FollowSymLinks
 
#
# Setting rewrite rules
#
 
<IfModule mod_rewrite.c>
RewriteEngine On
# Set next line to your Wolf CMS root - if not in subdir, then just /
RewriteBase /
 
# START FUNKY CACHE RULES
 
# Check for cached index page from static cache folder.
RewriteCond %{REQUEST_METHOD} ^GET$
RewriteCond %{REQUEST_URI} ^/$
RewriteCond %{DOCUMENT_ROOT}/cache/index.html -s
RewriteRule ^$ %{DOCUMENT_ROOT}/cache/index.html [L]
 
# Check for other cached pages from static cache folder.
RewriteCond %{REQUEST_METHOD} ^GET$
RewriteCond %{DOCUMENT_ROOT}/cache%{REQUEST_URI} -s
RewriteRule (.*) %{DOCUMENT_ROOT}/cache%{REQUEST_URI} [L]
 
# END FUNKY CACHE RULES
 
# Rules to allow install sequence to test for mod_rewrite support
RewriteRule ^wolf/install/index.html$ wolf/install/index.php?rewrite=1 [L,QSA]
RewriteRule ^wolf/install/index.php$ wolf/install/index.php?rewrite=1 [L,QSA]
RewriteRule ^wolf/install/$ wolf/install/index.php?rewrite=1 [L,QSA]
 
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-l
# Main URL rewriting.
RewriteRule ^(.*)$ index.php?WOLFPAGE=$1 [L,QSA]
 
</IfModule> 
Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!

Re: Funky Cache

Just tried the updated Funky Cache plugin.
When I have it enabled and with the .htaccess rules and cache dir setup
it breaks the HTML of the website resulting in a white page.
The website renders fine when I disable the plugin.

I should note that the plugin does save files just fine to its cache dir.
The content of those are correct.

Last edited by Fortron (2012-01-21 18:26)

Re: Funky Cache

Fortron wrote:

Just tried the updated Funky Cache plugin.
When I have it enabled and with the .htaccess rules and cache dir setup
it breaks the HTML of the website resulting in a white page.
The website renders fine when I disable the plugin.

I should note that the plugin does save files just fine to its cache dir.
The content of those are correct.

Do you get any errors in the web server's error log?
Is Wolf running in the root of the site or in a subdirectory?

Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

David wrote:

Here's the .htaccess as used with Funky Cache - the bit between the comments is just a copy/paste from the code given as "example" in the embedded doc (and I used the /cache location also) (obviously I might have done something quite stupid big_smile):

Are the settings like this?

Yes
.html
/cache/
Wolf CMS founder and lead developer
Please always check the Support forums and Wiki before asking. (My Ohloh account.)
Like Wolf CMS? Consider making a financial contribution or see our financial report first.

Re: Funky Cache

mvdkleijn wrote:

Do you get any errors in the web server's error log?
Is Wolf running in the root of the site or in a subdirectory?

Errorlog contains no errors.
Wolf is running in root.

Tried it on a different website (different host too) and again no errors in the errorlog.
Some observations:

1. When Funky is enabled it prints Cache miss... even though it saves different pages to the cache directory, the content is allways that of the index though.
2. The htaccess rules prevent external files from being loaded (CSS, javascript, images)
or perhaps its due to Funky?
3. When the htaccess rules are removed and Funky is still enabled
it will only return the content of index, despite visiting different pages.

Last edited by Fortron (2012-01-21 20:37)

50

Re: Funky Cache

mvdkleijn wrote:

Are the settings like this?

Yes
.html
/cache/

Yep. hmm

Using Wolf CMS professionally and for profit? Please consider supporting Wolf financially. Thanks!