Data Service Caching

When you deploy a data service, you specify whether the data service will be cached. When a data service configured for caching is executed, it does not actually run if there is a valid cached result—the result is simply returned from the cache. This is true of both transactional and nontransactional data services. However, the caching behavior of transactional data services can be more complicated.

Suppose you have a transactional data service called ParentDS that receives input from another data service, ChildDS. If you configured ParentDS to cache its results and a valid cached result exists when ParentDS is called, the data service does not run—and therefore there is no transaction.

If you configured ParentDS not to cache its results and checked the Include input data services referenced by this data service box when you created the view model, ChildDS is always executed when ParentDS is called—even if ChildDS is cached, ParentDS will not retrieve a cached result.

If you configured ParentDS not to cache its results and did not check the Include input data services referenced by this data service box when you created the view model, the results of ChildDS will be retreived from cache if ChildDS is configured for caching. ParentDS runs ChildDS only if ChildDS is not configured for caching or if no valid result exists in the cache.

For product-related issues, contact Sybase Technical Support at 1-800-8SYBASE. Send your feedback on this help topic directly to Sybase Technical Publications: pubs@sybase.com