[TYPO3-core] RFC: #9599: [felogin] Enable Caching "USER" instead of "USER_INT"

Dmitry Dulepov dmitry.dulepov at gmail.com
Mon Oct 27 12:33:17 CET 2008


Hi!

Steffen Kamper wrote:
> attached is a new patch which change the USER to USER_INT using the
> convertToUserIntObject()-option.

This function was meant for different purpose. It will not work in
this case. The use case is described in the original RFC. Here it is
briefly.

convertToUserIntObject() is for plugins, whose caching can be
disabled dynamically by the TS configuration. For example, many
plugins have setting named like "allowCaching" in their TS. Such
plugins are defined as USER. If their TS setting is set to 0,
currently plugins use $TSFE->set_no_cache() to disable caching for
the whole page, which badly affects performance.
convertToUserIntObject() allows to convert USER object to USER_INT
object on the fly for such plugins. They do not have to forbid whole
page caching.

Why does it work for those extension and not for felogin?

When you change settings in TS (for example, set allowCaching=0),
cache for the page tree is cleared. Therefore the plugin will be
executed on the next page load in FE. It will check if it should be
cached or not. If not, it will convert itself to USER_INT by calling
convertToUserIntObject(). Any further requests to page will fetch
content from cache and run this plugin as USER_INT. The setting does
not depend on the user login, it is "static".

In case of felogin this will not work because there is no "static"
setting. Condition is the only way.

-- 
Dmitry Dulepov
TYPO3 translations support
My TYPO3 book: http://www.packtpub.com/typo3-extension-development/book
In the blog:
http://typo3bloke.net/post-details/max_os_x_use_php_help_in_chm_format/


More information about the TYPO3-team-core mailing list