Adaptive Personalization Manual / Version 2110
Table Of ContentsSelection rules as well as segment conditions are stored in textual form in document properties. To be evaluated in the CAE, they have to be parsed and transformed into an executable form. This transformation is expensive and thus should only be performed if necessary, that is, if the corresponding document properties were modified. Therefore, you should use CoreMedia data views and the CoreMedia cache for caching.
SelectionRulesProcessor
as well as ConditionsProcessor
can be
cached. In your content beans, use a property getter that returns the appropriate processor
for your document and create a data view with association type 'static' for this getter. In
the methods that use the processor, access it via the getter. This guarantees that parsing is
only done if necessary.
If you use the SegmentSource
, you do not need to care about caching segment
conditions, as this is done by the source itself. You'll find an example data view declaration
for the type CMSelectionRules
in the CoreMedia Content Cloud p13n extension. For
further information on how data views work, refer to the
Content Applications Developer Manual.