MashZone NextGen Administration : MashZone NextGen Server Configuration : BigMemory for Caching, Connections and MashZone NextGen Analytics : Configuring Mashable/Mashup Response Caching : Response Caching Example
Response Caching Example
The relationship between global, mashable-type and artifact level configuration for response caching provides a wealth of control, but sometimes can be confusing. This example illustrates some common configuration patterns and behavior.
Event
Cache Entry
1.
UserA turns response caching on for a spreadsheet mashable he just registered.
The caching configuration is saved, but no caching will occur because response caching has not been enabled.
2.
A MashZone NextGen administrator turns response caching on in the Admin Console.
Response caching is now allowed but can occur only for the spreadsheet mashable configured in step 1.
Note:  
If no caching configuration had been set in step 1, no response caching would occur after this step as both are required for caching to occur.
3.
A MashZone NextGen administrator turns caching on for all RSS and Atom mashables, but does not configure an expiration period.
UserA adds a block to a mashup in Wires for the Yahoo Financial RSS mashable and previews the results.
The response from Yahoo is cached with an expiration of 5 minutes, taken from the global default expiration period.
4.
The owner of the Yahoo Financial RSS mashable changes the response cache expiration period for this mashable to 1 minute.
Within seconds UserA adds a filter block to his mashup, connects the Yahoo Financial block and previews the result of the filter.
The existing response cache entry for Yahoo Financial is used as the input to the filter block.
This cache entry will remain for the full 5 minutes and then expire. All subsequent responses for the Yahoo Financial mashable will use a 1 minute expiration period.
5.
UserA finishes his mashup and creates a basic app with it. He turns response caching on for his mashup and assigns an expiration period of 15 minutes.
UserB uses this app. Three minutes later, UserC also uses this app.
The mashup is run and caches its response when UserB runs the associated app. The mashup also runs the Yahoo Financial mashable and that response is also cached.
When UserC runs the app three minutes later, the cache entry for Yahoo Financial has expired. The app, however, simply uses the cached mashup response which is based on Yahoo Financial results from three minutes before that may now be considered stale.
6.
A MashZone NextGen administrator sets the default response caching expiration period for all RSS and Atom mashables to 3 minutes.
As RSS or Atom mashables are run, their responses are cached for 3 minutes, except for Yahoo Financial which is cached for 1 minute.
7.
UserA registers a REST mashable with several operations for the Human Resources system in his organization. To ensure that sensitive information is not cached, he enables caching for the REST mashable as a whole but turns off response caching for two sensitive operations.
When users work with the REST mashable, or any mashup or app based on this mashable, responses will be cached except for those operations where caching has been disabled.
8.
A MashZone NextGen developer creates a mashup that uses several Atom mashables. In the mashup he adds the HTTP Cache-Control header with a value of no-cache to the response of each of the Atom mashable invocations.
When this mashup is used, each Atom mashable will be invoked every single time with no response caching because of the HTTP response headers.
Copyright © 2013-2016 Software AG, Darmstadt, Germany.

Product LogoContact Support   |   Community   |   Feedback