
The following table describes the profile properties that you can define in the deployment descriptor - in the <component-profile> element for your component - in order to control the caching of your component's content:
|
Property |
Description |
|---|---|
|
CachingLevel |
Indicates the type of cache, as follows:
|
|
ValidityPeriod |
Indicates how long the cache is valid, in milliseconds. -1 indicates the cache never expires. |
|
ALLOW_BROWSER |
Indicates if browser caching is used:
|
The following is a deployment descriptor that defines a component with a CachingLevel of session and ValidityPeriod of 2 seconds:
<application>
<application-config/>
<components>
<component name="session">
<component-config>
<property name="ClassName" value="myApp.myCompnent"/>
</component-config>
<component-profile>
<property name="CachingLevel" value="Session"/>
<property name="ValidityPeriod" value="2000"/>
</component-profile>
</component>
</components>
</application>