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

11 months 5 days ago - 11 months 5 days ago #70731 by seabird
Hello,

I created a date field that changes the expired date of an article with a plugin I created.
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

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

11 months 5 days ago - 11 months 5 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 review. Thanks!

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

11 months 5 days ago - 11 months 5 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 review. Thanks!

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

11 months 5 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 review. Thanks!

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

11 months 5 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
© 2018 Flexicontent. All Rights Reserved.