Scheduled offline caching
Summarize
Summary of Scheduled offline caching
Scheduled offline caching in ServiceNow Zurich release enables field technicians to receive automated, scheduled updates to their offline data cache based on their work schedules. This feature ensures technicians have up-to-date information available even without continuous internet connectivity, improving productivity and data accuracy in the field.
Show less
Key Features
- Agent Schedule Plugin: Activation of the
com.snc.agentscheduleplugin is required to enable scheduled offline caching functionality. - Work Schedule Configuration: For Mobile Agent and other mobile clients, work schedules must be created to define when offline caches are updated. This involves entries in the
Offline download schedule (syssgofflinedownloadschedule)table for client types and schedules in theAgent Work Schedules [agentworkschedule]table for users. - Automated Background Jobs: Your instance runs scheduled background jobs that populate the
Agent Daily Schedules [agentdailyschedule]table and generate offline payloads. These jobs operate only for users who have enabled background downloading in their mobile app. - Event Tracking: Offline payload creation and delivery are tracked through records in the
Events [sysevent]table, allowing administrators to monitor payload generation and push notifications. - System Properties for Configuration: Several properties allow fine-tuning of the offline caching process, including enabling scheduled downloads, setting payload generation offsets, daily reminder offsets for manual downloads, payload refresh frequency, and attachment size limits.
Key Outcomes
- Field technicians automatically receive updated offline data caches aligned with their work schedules, ensuring they have current information while working remotely.
- Administrators can customize the timing and behavior of offline cache generation and reminders through system properties, optimizing performance and user experience.
- Background downloading minimizes manual intervention by users, reducing the risk of working with stale data.
- Visibility into offline payload events through the Events table supports troubleshooting and auditing of offline caching activities.
Configure offline caching so your field technicians can receive scheduled updates to their offline data cache. Scheduled downloads are based on the user's work schedule.
Activate the Agent Schedule plugin
To enable and configure scheduled offline caching, the Agent Schedule plugin [com.snc.agent_schedule] must be activated. For details on plugin activation, see Activate a plugin.
Create work schedules for offline caching
For mobile clients other than Mobile Agent, ensure that an entry in Offline download schedule (sys_sg_offline_download_schedule) exists for the client type, for example, Request. This entry specifies the table that has the offline download schedules for the agents or technicians. Mobile uses the schedule from this table for scheduling offline cache generation. To populate schedules for each user, a scheduler script can be used like in Field Service Mobile.
For Mobile Agent, the entry is created when the plugin is activated. After activating the plugin, you must create work schedules for the agents or technicians to enable users to automatically receive scheduled offline caches. This can be done directly through the Agent Work Schedules [agent_work_schedule] table. For more information on how to create schedules through this table, see Create a work schedule for an agent or technician.
Based on the records from the Agent Work Schedules table, your instance runs background scheduled jobs that create schedules in the Agent Daily Schedules [agent_daily_schedule] table. Within these schedules, agents will receive a silent push sometime throughout their scheduled day.
The offline payloads that your instance generates are based on the times recorded in the Agent Daily Schedules. These can be found in the Events [sysevent] table. Use the records in the Event table to track these payloads, and info about when they are created and when they are sent to the agents.
Scheduled Jobs associated with offline caching
These scheduled jobs are automatically scheduled for only users who enable background downloading on their app. For information on how users can enable this feature, see Offline mode for mobile.
- Populate Agents Daily Schedule Table
- This job runs once daily for all users with background downloading set to true.
- Scheduled Download of Offline Payload
- This job creates an event for the first payload of the day in the [mobile_offline_payload_gen_queue] table.
Offline scheduling system properties
Use the following properties on the System Properties [sys_properties] table to configure scheduled offline caching.
| Property | Description |
|---|---|
| glide.sg.offline.scheduled_download.enabled | Enables scheduled downloading for all Mobile Agent app users. |
| glide.sg.offline.scheduled_download.cachesync_offset | Determines when your instance starts payload generation prior to schedule. Value
determines how many minutes before the user schedule payload generation begins. Note: Be sure not to set the value of this property earlier than your Mobile
Offline Scheduling job is runs. Doing so will prevent offline payloads from being
generated. |
| glide.sg.offline.scheduled_download.reminder_offset | Determines when your instance sends your users a daily reminder to manually download a cache. The instance sends this reminder only when there is no cache or the cache is expired. Value determines how many minutes before a user schedule your instance sends this reminder. |
| glide.sg.offline_payload.refresh_frequency | Determines refreshTimestamp frequency of payloads. Value represents this frequency in minutes The default value is 480. |
| glide.sg.offline.attachment.max_total_bytes | Determines the maximum size allocated for all attachments in a cache. Value is represented in Megabytes (MB). The maximum value is 2048 MB. |
For information on more offline related system properties, see, Configure offline mode behavior.