Configuring external temporary storage options for attachments in offline mode
Take advantage of your external storage solutions, such as Amazon S3 or Microsoft Azure, by using these solutions to store temporary files that are sent from your offline-enabled mobile app.
By default, Pega Platform stores all attachments that the mobile device sends to the server in the local data storage.
- Obtain access to an Amazon S3 bucket or Microsoft Azure container.
- Obtain an Amazon Web Services access key or an Microsoft Azure user name and a corresponding password.
- Choose a root path for your repository.
In a standard offline workflow, users process cases and can add attachments to these cases. Your app records all actions that users perform while they are offline, in the action queue. When users regain network connectivity, the mobile client sends all actions and attachments that are referenced in the action queue to the default Pega Platform temporary storage (JDBC data source). Apart from replaying all queued actions, the Pega Platform server fetches all attachments from the temporary storage, and then sends them to the target data storage. Afterward, the temporary storage is cleaned.
The default configuration uses the storage/class/uploads:/type dynamic system setting with the value of datastore. You can change the default configuration to use an external storage service as a temporary storage with a set of dynamic system settings.
In the navigation pane of Dev Studio, click Records.
Expand the SysAdmin category, and then click Dynamic System Settings.
Open and configure the dynamic system settings that are required to use an external temporary storage service.If the records list of dynamic system settings in your Pega Platform environment does not have the following entries, create each one. For more information, see Creating a dynamic system setting.
Dynamic system setting (short description) Owning ruleset Value storage/class/uploads:/type Pega-ProcessCommander
- For Amazon S3: aws-s3
- For Microsoft Azure: azureblob
storage/class/uploads:/bucket Pega-ProcessCommander Amazon S3 bucket or Microsoft Azure container location where the files are stored. storage/class/uploads:/accesskeyid Pega-ProcessCommander Amazon S3 access key or Microsoft Azure user name. storage/class/uploads:/secretaccesskey Pega-ProcessCommander Amazon S3 or Microsoft Azure password. storage/class/uploads:/rootpath Pega-ProcessCommander Amazon S3 or Microsoft Azure root path for the repository.
For each dynamic system setting that you modify, in the upper-right corner of the rule form, click Save.