Joomlatwork
Welcome, Guest. Please login or register.
Did you miss your activation email?
May 24, 2013, 11:58:37 AM

Login with username, password and session length
Search:     Advanced search
18428 Posts in 6352 Topics by 11308 Members
Latest Member: Slicjaimi
* Home Help Search Login Register
+  Joomlatwork
|-+  Joomla accelerate component
| |-+  Support questions
| | |-+  (Is the) Cache cleared after edit?
« previous next »
Pages: [1] 2 3 Print
Author Topic: (Is the) Cache cleared after edit?  (Read 9847 times)
simonknee
Newbie
*
Posts: 8


View Profile
« on: February 23, 2007, 12:05:40 AM »

Hi,

Just put this on my site and it really helps things speed up to what the average user expects.

I was hoping that the cache for a particular item would get cleared after the item is edited in the front or back-end. This appears to be the case with the standard joomla cache (though I don't know if this is really what is going on since the joomla cache makes little difference once you have sef (artio) on the site).

If this is supposed to be the functionality then any idea why it doesn't work for me. If not wouldn't this be a good idea.

My content changes infrequently and I can remove from the cache any dynamic content but when a user makes an edit it would be nice if they could see the change straight away.

Simon
« Last Edit: February 23, 2007, 10:49:47 AM by simonknee » Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #1 on: February 23, 2007, 08:11:19 AM »

Quote
I was hoping that the cache for a particular item would get cleared after the item is edited in the front or back-end. This appears to be the case with the standard joomla cache (though I don't know if this is really what is going on since the joomla cache makes little difference once you have sef (artio) on the site).

Please note that this is not the case as explained in the documentation of the component. It is indeed a feature that will be nice to remove the "whole" cache if an content item is created. For my idea: Is your question only related to Joomla content items?

Regards,

Richard
Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #2 on: February 23, 2007, 10:49:19 AM »

This should be made more clear in the product description. I read all of it yet do not find part that tells me this.
If it is there it is not prominent enough.

As to your idea...

Yes I am talking about joomla content items.
No I do not want to clear whole cache.

When a user clicks save on a content item (front or back-end) then the corresponding cache entry shouuld be marked as expired.
This would require a modification to the joomla core code I expect.
On the other hand I cannot see that this would be too hard, just some extra php activated when the user clicks "Save" or "Apply".
Is it not possible to trap these actions and redirect the code to a bit of your own??

(Edit) Ah I do understand your idea as that would mean new content would show up in menu's etc. Good idea. It would help my situation too. I have a site that generates few new content items but the existing ones are often edited. So targetting the content directly is more efficient.

This would make a great component amazing as it would seem as though there is no cache!!!

http://www.strongroom.com

Simon
« Last Edit: February 23, 2007, 10:55:29 AM by simonknee » Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #3 on: February 25, 2007, 11:29:06 AM »

ANy further thoughts on this?
Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #4 on: February 25, 2007, 11:42:07 AM »

The only 2 options that I can think of is to:
a) make an option within the configuration that the cache is cleared when a new content item is created;
b) Clear specific URL's from the URL repository when a new content item is created.

This is because its hard (or impossible) to detect where the specific content items are displayed. URL's and the content can be different showed and included within the several blogs etc... Therefor the solutions is to clear specifc URL's marked within the URL repository when a new / update content item is made. For example this would mean that you specify the frontpage and the blog URL's to be cleared.

Is this an option?

Richard

Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #5 on: March 01, 2007, 02:52:47 PM »

This is exactly what I was thinking.

You say "Is this an option?", do you mean "Would this do what you are asking" if so the answer is a definite yes, both a and b are exactly what I want.

I think the logic should apply like this:

1. If content is created/updated then clear any cached url which references this content explicity.
2. Allow an option in the Url Repository to "Clear on New/Update"

The first rule targets explicit entries such as content items.
The second rule would apply when _any_ item is created or changed even if the cached url does not reference the item. The user can then set this "on" for frontpage, blogs, feeds, etc etc

Clearing the whole cache does work but is a waste of the cache.

Simon
« Last Edit: March 01, 2007, 02:58:33 PM by simonknee » Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #6 on: March 01, 2007, 05:21:19 PM »

I must think this over how to solve this from the technical part. Should be possible to implement this...

regards,

Richard
Logged
rolffey
Newbie
*
Posts: 2


View Profile
« Reply #7 on: March 15, 2007, 03:48:57 PM »

Hi Richard
The point that Simon explained is very important indeed. We devlop sites for many customers and one of them with heavy traffic. I installed the "Cache accelerator" but since after EDIT/SAVE the content is still the "old" one, I had to deactive the tool. Mainly because many people are working on the site every day. How can I tell them to just wait until the cache is refreshed? Some are Backend Admins and some frontend editors.
Most of the time 95% of the content is the same over many weeks/months and some pages change very quickly. If you can clear the cache of "that specific" item that has beed edited - or that module that has new parameters etc., then this tool can be used in all of our projects.
Until then we unfortunately had to deactivated it for simpicifaction of work.
Thank you for such great tools!!!
Regards
Rolf
Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #8 on: March 15, 2007, 04:04:54 PM »

Rolf,

I understand the needs. I currently thinking to make it possible within the configuration that when a joomla content page (!) is updated / added / deleted that some cache pages can be removed (= based on URL's) or that the whole cache is deleted.

Richard
Logged
rolffey
Newbie
*
Posts: 2


View Profile
« Reply #9 on: March 15, 2007, 08:01:06 PM »

Dear Richard.
I guess this is the right way. Even when the whole cache would be cleared the advantage of your component would be huge since most of the time a day the site is not altered.
Thanks!
Regards
Rolf
Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #10 on: March 29, 2007, 01:27:24 AM »

Any prgress update on implementing this Richard?

Even if you only got the "clear whole cache" to work it would improve the module 100%. It occurs to me that with this option you can leave the cache time set to "forever"!

Simon
Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #11 on: March 29, 2007, 06:20:20 AM »

Not yet  Cry, planned to do this the comming week.

Richard
Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #12 on: March 30, 2007, 09:27:39 PM »

Coolio, can't wait.

Simon
Logged
joomlatwork
Administrator
Hero Member
*****
Posts: 2817


View Profile Email
« Reply #13 on: April 10, 2007, 10:04:59 PM »

Finished the solution.

If someone please want to test it out?

What I did is patched the backend of the joomla administrator part when a content item is saved the cache can be cleared (is configurable), Therefore the admin.content.php is patched and should be replaced. Therefore I will need to now the joomla version you are using (presumable 1.012).

I will make a package tomorrow. Please sent me an email if you want to test this out. Otherwise I will released it within 3 weeks from now.

Regards,

Richard
Logged
simonknee
Newbie
*
Posts: 8


View Profile
« Reply #14 on: April 20, 2007, 10:49:20 PM »

2 months from suggestion to implementation, great support, nice one Richard!!

I'll let you know if I get any more bright ideas ;-)

Simon
Logged
Pages: [1] 2 3 Print 
« previous next »
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.12 | SMF © 2006-2009, Simple Machines LLC Valid XHTML 1.0! Valid CSS!