[TYPO3-core] RFC #9284: Feature: tt_content.starttime/endtime have now effect on caching
Martin Kutschker
masi-no at spam-typo3.org
Tue Sep 23 15:54:30 CEST 2008
Ernesto Baschny [cron IT] schrieb:
> Martin Kutschker wrote: on 23.09.2008 10:10:
>
>>> Complicated is the fact that you need to collect info from records not
>>> rendered at all, for example for those which start-time in future.
>> I didn't consider this.
>
>>> So
>>> the CONTENT query will already filter those out at SQL-time, but you
>>> need to look at them too, if you want to calculate the "earliest cache
>>> expiration time".
>> But how should this be done? There may be many records available but the
>> display logic can be arbitrarily complex.
>>
>> I cannot think of any reliable way to get to that data. Simply taking
>> all records into account is easy but not necessarily correct.
>
> In CONTENT and RECORD it might be "easy", simply execute the same query
> we already make twice, once with enableFields and once without
> start/endtime filtering. Use the first one for rendering, the second one
> for looking up cache expiration.
I actually thought about doing a query without any limit execept
"deleted=0" and do the processing in PHP from the start, so you need
only one query. IMHO we shouldn't burden the DB server with more queries
for rare edge cases - clear cache at midnight is good enough for many sites!
> Cache expiration needs to propagate down the cObject hierarchy, so that
> the top level cObject (e.g. the "PAGE" object) has information based on
> all objects below it (for example a TEMPLATE, which includes a COA,
> which might include an USER and a CONTENT, etc).
Why add some extra hoops? This is the task of TSFE. I don't see why the
simple but effective way the last-generated info is collected isn't good
enough for the caching time. No need to pass infos around in
hierarchies, stacks or whatever.
> I can imagine that a OO-based framework could provide very good new
> concepts for the already great TypoScript and "cObject" concept, see below.
This will change very much and is beyond the scope of this thread.
Masi
More information about the TYPO3-team-core
mailing list