Skip to main content

Cached Datalayers - deleting a cache

Comments

1 comment

  • VISUI

    Your data warehouse workflow should trigger a Logi process task which builds the cache.  Most properties within a DataLayer.Cache can be tokenized, including the "Expiration Now" properties.  Set it to "@Request.ExpirationNow~" on all of the DataLayer.Cache elements that way you can simply run the process task with "ExpirationNow=True" to renew all cached datalayers built within the process task.

    Another more complex option would be to set the Expiration Time Span to 48 hours but tokenize the Cache Key with a Session token.  This session token would be based on some value written within a database for "in-process" cache key for whenever your data warehouse process completes.  Then the data warehouse process should run the process task which builds your cache using this in-process CacheKey value.  At the end of this process update the database value used by the application for the "live" cache key to the one used for "in-process".  Your application will now store two versions of the cache for each 24 hour period.  In your application's startup process set a Session token to the "live" Cache Key value found in the database.  This should eliminate situations where a user runs a report after the cache has expired, but before the new cache is built, because they will still retrieve the old "live" cache key during their startup process.  You could then periodically check within the user's session to see if the new cache key is available.


    0

Please sign in to leave a comment.