[TYPO3-english] Cache settings dilemma

Stephan Schuler Stephan.Schuler at netlogix.de
Wed Oct 22 15:21:28 CEST 2014


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA256

Hey Loek.

You clearly want to use cache tags.

If a new page renders news lists, the page needs to be tagged by "tx_news_domain_model_news".
If a page renders a single news either by being a news details page or e.g. based on "more like that" (solr feature), this page needs to be tagged by "tx_news_domain_model_news_$newsId".

Now whenever an editor adjusts a news record in the backend, all caches tagged by both, "tx_news_domain_model_news" as well as "tx_news_domain_model_news_$newsId" are flushed automatically.

So that's not a dilemma but actually completely handled by TYPO3 internals these days. The only thing you need to do: Use prober tagging.

<pre>
/** @var \TYPO3\CMS\Frontend\Controller\TypoScriptFrontendController $typoScriptFrontendController */
$typoScriptFrontendController = $GLOBALS['TSFE'];
$typoScriptFrontendController->addCacheTags(array( tx_news_domain_model_news', 'tx_news_domain_model_news_123'));
</pre>

Regards,


Stephan Schuler
Web-Entwickler

Telefon: +49 (911) 539909 - 0
E-Mail: Stephan.Schuler at netlogix.de
Website: media.netlogix.de



- ----------------------------
Woche der 79ers vom 27. bis 30. Oktober: Microsoft SCCM, Veeam Backup, Citrix XenDesktop, Sophos
4 Tage, 4 Themen – je 79 Euro. Jetzt anmelden unter http://it-training.netlogix.de/leistungen-angebote/79ers
- ----------------------------




netlogix GmbH & Co. KG
IT-Services | IT-Training | Media
Neuwieder Straße 10 | 90411 Nürnberg
Telefon: +49 (911) 539909 - 0 | Fax: +49 (911) 539909 - 99
E-Mail: info at netlogix.de | Internet: http://www.netlogix.de

netlogix GmbH & Co. KG ist eingetragen am Amtsgericht Nürnberg (HRA 13338)
Persönlich haftende Gesellschafterin: netlogix Verwaltungs GmbH (HRB 20634)
Umsatzsteuer-Identifikationsnummer: DE 233472254
Geschäftsführer: Stefan Buchta, Matthias Schmidt



- -----Ursprüngliche Nachricht-----
Von: typo3-english-bounces at lists.typo3.org [mailto:typo3-english-bounces at lists.typo3.org] Im Auftrag von Viktor Livakivskyi
Gesendet: Mittwoch, 22. Oktober 2014 14:28
An: typo3-english at lists.typo3.org
Betreff: [TYPO3-english] Re: Cache settings dilemma

Hi, Loek.

You can try
TCEMAIN.clearCacheCmd = cacheTag:pagetag1 [1] and add page tags to the required pages, then there will be less messages in log and at same time not all the pages caches will be flushed. This should be available since 6.1, afaik.

But be aware, that this command sometimes may slow down your BE [2]

[1]: http://docs.typo3.org/typo3cms/TSconfigReference/PageTsconfig/TCEmain/Index.html#clearcachecmd
[2]: http://forum.typo3.org/index.php?t=msg&th=206148
_______________________________________________
TYPO3-english mailing list
TYPO3-english at lists.typo3.org
http://lists.typo3.org/cgi-bin/mailman/listinfo/typo3-english

-----BEGIN PGP SIGNATURE-----
Version: PGP Universal 3.3.2 (Build 15238)
Charset: utf-8

wpUDBQFUR69Zpp0IwsibV8MBCF5LBAC/okdOBEAX/DKL1BzfyerkmcXpVj662GoX
7bjYB1igkrbjxwTG3P76pMyoGzYYmdiTNdgMkyLU86OuITQmoEu5/d5jzTGXLRI1
IzeSUH8nfIHHxcIorJjqg+e5iXMWr+AEWiPNdIe+SNfV8h8Y5Rrdg2yT++EyQI7B
ZY3ekj5Dyw==
=loIa
-----END PGP SIGNATURE-----


More information about the TYPO3-english mailing list