Quantcast
Viewing all articles
Browse latest Browse all 295826

How Drupal 8 caching mechanism works?

Is there any flow for Drupal 8 caching mechanism? Can I decide that a particular page cannot be cached for certain conditions by some hook in Drupal 8?

I have tried out Cache Context, Cache Max-age, Cache tags invalidation. I didn't get a hook for theme or module which is not being cached by Drupal.

Finally get a solution using

\Drupal::service('page_cache_kill_switch')-?>trigger();

But this will remove the entire page cache for everytime.

I just want to show the updated content for anonymous users which will change in a day time / 24 hours span. Can I have a solution for the same.


Viewing all articles
Browse latest Browse all 295826

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>