Skip to main content


         This documentation site is for previous versions. Visit our new documentation site for current releases.      
 

Caching data in offline-enabled mobile apps

Updated on April 27, 2022

Help users begin their work without unnecessary delays by enabling caching in offline-enabled mobile apps and including the cached data in the app executable files. By caching common rules and storing them in the app bundle, you ensure that the app starts faster when users launch it for the first time.

Before you begin:
Important: Consider the following information before enabling caching and including the cached data in the app bundle:
  • Do not enable caching of common data in the app development testing stages because frequent model changes in these stages require forced full synchronizations to update the model. For more information, see Propagating application model changes to offline-enabled mobile apps.
  • When you include the cached node-scope data pages in the app installation package, you might expose potentially sensitive data when, for example, you distribute the app through Google Play or the Apple App Store.
  • Depending on your application model complexity, the size of the app installation package might significantly increase when you include the cached content and node-scope data pages in the app bundle.
  • If you circumstance rules and data pages in your application, consider not enabling caching. The app evaluates circumstancing during packaging, which means that all users only get the data that matches the circumstancing conditions for the first user. For more information, see Creating a rule specialized by circumstance.
After users log in to the app, the packaging process determines the scope of the data that the app downloads during data synchronization. When you configure your offline-enabled app to cache common data, such as rules and static data, the package already contains the cached content and can immediately download the necessary data. Further, you can include the cached data in the app executable file. This approach ensures that the initial data synchronization is faster because the app synchronizes only the data that differs between the package and the current server state.
  1. Open your mobile channel:
    1. In the navigation pane of App Studio, click Channels.
    2. In the Current channel interfaces section, click the tile that represents a mobile channel for your app.
  2. On the mobile channel page, on the Configuration tab, click the Offline category.
  3. Expand the Advanced section, and then, in the Caching section, select the Cache common rules checkbox.
  4. Optional: To control the caching of node-scope data pages, perform one of the following sets of actions:
    • To cache specific node-scope data pages in addition to common rules, select Additionally cache node scope data pages listed below, and then enter the names of the node-scope data pages.
    • To cache all node-scope data pages, select Additionally cache all node scope data pages except for those listed below.
    • To cache all node-scope data pages in addition to common rules, but also exclude specific node-scope data pages from caching, select Additionally cache all node scope data pages except for those listed below, and then enter the names of the node-scope data pages that you want to exclude.
  5. Optional: To include the cached data in the app executable file for even faster startup, select the Include cache contents in the installation package checkbox.
  6. Click Save.
Result: When you build the mobile app, the common rules and data that you specified are cached, and, optionally, stored in the app executable file.
  • Previous topic Declaring a data page as large
  • Next topic Disabling processing of attachments and signatures in offline mode

Have a question? Get answers now.

Visit the Support Center to ask questions, engage in discussions, share ideas, and help others.

Did you find this content helpful?

Want to help us improve this content?

We'd prefer it if you saw us at our best.

Pega.com is not optimized for Internet Explorer. For the optimal experience, please use:

Close Deprecation Notice
Contact us