Auto-refresh in Workshop

Workshop auto-refresh allows builders to easily create applications that automatically update as data changes in Foundry. Providing reliable, up-to-date information to users is critical for supporting operational workflows, and Workshop makes this possible in a just few clicks.

With auto-refresh, you can register object sets within a module to be watched for updates from anywhere in Foundry. When an update occurs, all data in the current module will automatically refresh without user interaction. Examples of update sources include ontology data updates due to Actions taken by other users, edits from an upstream data integration, or new records from a streaming data source. In these cases, auto-refresh will update the data in the current module.

Auto-refresh is valuable in cases where data freshness is a priority, including but not limited to live dashboards and collaborative workflows.

You can enable Auto-refresh within a specific Workshop module. Navigate to the Auto-refresh configuration options toward the bottom of the Settings panel in the Workshop editor.

Auto-refresh configuration in settings panel

Auto-refresh may trigger an increased data load volume and associated costs. Builders may choose not to enable the feature for workflows where live data is less necessary.

Settings

Auto-refresh settigs

To update auto-refresh settings, select Auto-refresh in the Settings panel. Then expand the Settings section on the bottom of the panel.

Minimum seconds between refresh

This setting allows a module builder to configure the minimum amount of time between data refreshes. This setting will not impact initial refresh latency, but rather ensure that a module is not constantly reloading. The current minimum, or most frequent, refresh rate is 10 seconds, which ensures stability of services due to the increased load from auto-refreshing.

Disable in edit mode

This setting allows module builders to turn off Auto-refresh behavior while in edit mode. A builder may wish to use this if auto-refreshing data in edit mode distracts from the building experience or is not needed. Auto-refresh will remain configured and active in view mode with this setting enabled.

Limitations

Object Storage V2 (OSv2)

Auto-refresh is limited to OSv2-backed object types. This limitation includes object sets with linked objects of OSv1-backed object types used in the object set definition.

Learn more about migrating from OSv1 to OSv2.

Auto-refresh of linked object types

Auto-refresh does not automatically watch for updates of linked object types. This means linked object properties and linked object aggregations of a watched object set will not auto-refresh unless the linked object type is also explicitly watched.

Filters

Some object set filter types are not currently supported by Auto-refresh, such as terms, phrase, multiMatch, prefixOnLastToken, and objectSetLink. Support for these filter types may be added in the future. As a workaround, you can watch an unfiltered object set of the same type. This may cause refreshing to happen more often than is necessary but should otherwise ensure that the object type is kept up to date within a module.

Visibility in module

Currently, object sets that have Auto-refresh enabled need to be used within a visible widget in a module to trigger an auto-refresh. This prevents auto-refreshes that would not affect the data that is displayed in your module. For example, if a registered object set is only used within a hidden drawer, auto-refresh will only occur while that drawer is open.

No inheritance of auto-refresh configuration from embedded modules

Embedding a Workshop module does not carry over the auto-refresh configuration of the embedded module. Auto-refresh must be explicitly configured for every module that you intend to use auto-refresh with.

Troubleshooting

If any errors occur that appear to be referencing auto-refresh issues, consider the following:

  • Ensure that all object types and link types are backed by Object Storage V2. In particular, watch for two object types backed by OSv2 that have a link type backed by OSv1, as this can cause errors with auto-refresh.
  • Ensure invalid object sets cannot be set at runtime, such as adding invalid filter types to an object set. It is possible for an object set to initially be compatible with auto-refresh, but it may end up in a state where it is unable to be watched for updates due to user interaction with the application.
  • Improving the stability of your network connection will directly improve the stability of the Auto-refresh feature. If the network is disconnecting and reconnecting, you may see errors notifying users when Auto-refresh is disabled.
  • In cases where you are not seeing expected refreshes, you may be watching too specific of an object set. Try watching a broader object set, like the base object set for a given type, or a wider filter. You can then define a variable with more specific filters downstream of this broader watched object set.
  • Check the browser console for more detailed error messages. Below, you can review details for some common errors that may occur while using auto-refresh:
    • InvalidObjectSetForPlanning: A watched object set contains a reference to an entity (either an object type or link type) indexed in Object Storage V1.