[Decrease cache expire time] Auto Unpublishing is delayed by e.g. 15 minutes

More
7 years 5 days ago - 7 years 4 days ago #70731 by seabird
Hello,

I created a date field that changes the expired date of an article with a plugin I created.
Code:
public function onAfterSaveItem( &$item, &$post ) { $date_fin=$post['custom']['date-de-fin'][0].' 23:00:00'; $db = &JFactory::getDBO(); $query = 'UPDATE #__content SET publish_down = "'.$date_fin.'" WHERE id = '. (int)$item->id; $db->setQuery($query); $result = $db->loadObjectList(); }

And with a cron I unpublish the item after expired date.



So, I wanted to test Plugin système FLEXIcontent. I select Unpublish to Items with expired dates. But it's strange the items are unpublish after some time ~ 15 min.
the item do not Unpublish intantaneously ???

Regards,

Eric
Last edit: 7 years 4 days ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
7 years 4 days ago - 7 years 4 days ago #70737 by ggppdk
Hello

yes that is expected behaviour if you have caching enabled
- our SQL queries use current time only every time the cache expires

if we used the real time all the time, the caching would not be possible


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Last edit: 7 years 4 days ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
7 years 4 days ago - 7 years 4 days ago #70738 by ggppdk
Hello

so if you need to have the views / modules updated immediately
then you will need to disable caching in Joomla Global configuration


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...
Last edit: 7 years 4 days ago by ggppdk.

Please Log in or Create an account to join the conversation.

More
7 years 4 days ago #70739 by ggppdk
Hello

a simpler solution that is good trade-off
is instead of disabling the caching, is to set your cache time to 1 or 2 minutes ...


-- Flexicontent is Free but involves a big effort on our part.
Like the our support? (for a bug-free FC, despite having a long list of functions) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing with a 5-star...

Please Log in or Create an account to join the conversation.

More
7 years 4 days ago #70743 by micker
maybe you can particpate to this plugin
github.com/micker/plug_automoveflexiitem
=> automove plugin item with flexicontent date field compatibility adding delay etc

FLEXIcontent is Free but involves a very big effort on our part.
Like the our support? (for a bug-free FC, despite being huge extension) Like the features? Like the ongoing development and future commitment to FLEXIcontent?
-- Add your voice to the FLEXIcontent JED listing reviews. Thanks![/size]

Please Log in or Create an account to join the conversation.

Moderators: vistamediajoomlacornerggppdk
Time to create page: 0.428 seconds
Save
Cookies user preferences
We use cookies to ensure you to get the best experience on our website. If you decline the use of cookies, this website may not function as expected.
Accept all
Decline all
Essential
These cookies are needed to make the website work correctly. You can not disable them.
Display
Accept
Analytics
Tools used to analyze the data to measure the effectiveness of a website and to understand how it works.
Google Analytics
Accept
Decline