TR50 Store and Forward
The TR50 feature supports an optional Store and Forward (S&F) capability.
When a TR50 connection can not be established with the
deviceWISE Cloud, TR50 commands can be stored locally on the
gateway.
The TR50 commands can be store in memory only or in disk
only. This storage option is part of a S&F profile.
When the TR50 connection is re-established, the stored
TR50 commands are forwarded to the deviceWISE Cloud using the
TR50 Command
Aggregator.
Aggregation while forwarding will happen regardless of the
Command Aggregation setting on
the TR50 Advanced Connection
Management tab, but will always use the TR50
Connection's Command Aggregation Interval (sec).
S&F capable actions
The trigger actions that are capable of using the TR50
S&F feature, do so by selecting a previously defined
S&F profile in the action's S&F
Profile parameter. If the trigger action selects
the default value of None for the
S&F Profile parameter, then the
trigger action will not be stored locally in the event the
TR50 connection is not established.
This allows the trigger author the flexibility of deciding
which trigger actions should be stored if the TR50
connection is not established, meaning it is not a single
setting for the TR50 connection.
The list of S&F capable actions is summarized here: Thing actions
The actions that are stored (S&F profile selected and TR50 connection not established), will:
- Complete after the corresponding TR50 command is added to the S&F queue, as opposed to completing after getting a response from the deviceWISE Cloud.
- Follow the Store and Forward route to the next
action to execute in the trigger. The Store and Forward
route is in addition to the normal Success and Failure
routes for the action.
- If the Store and Forward route is taken for the action, the Output parameters associated with that action will not be populated.
- Be added to the S&F queue while the TR50 connection is reestablished and previously stored TR50 commands are forwarded.
- Follow the Store and Forward route until the
S&F queue is emptied and the TR50 connection
returns to its normal Connected Status
and Standby S&F State.
When using the Store and Forward feature, trigger actions may take longer to execute based on the interaction with the S&F queues. You may need to review the trigger settings for Max in Progress and Queue Size. For more information, see Trigger settings.
S&F profiles
A TR50 S&F profile is defined with the parameters
for the S&F queue type, maximum size, etc.
Multiple S&F profiles can be defined on a gateway.
For more information, see TR50 S&F Profile Management tab.
S&F queues
A TR50 S&F queue is a storage mechanism for a S&F profile and TR50 connection combination:
- S&F capable trigger actions can select a S&F profile and select a TR50 connection. The combination of the S&F profile and the TR50 connection determines the TR50 S&F queue.
- Multiple actions in the same trigger could select
different S&F profiles and could also select
different TR50 connections.
For example, an "important" Publish Property action could use one S&F profile with a large storage size parameter. A "less important" Publish Property action might use a second S&F profile with a smaller storage size (or select None for the S&F profile).
For more information, see TR50 S&F Queue Management tab.
S&F State
A TR50 connection's S&F State is determined by the TR50 connection's Status and whether TR50 commands have been stored (or queued) for the TR50 connection. The S&F State reflects what is currently happening with the TR50 commands on the gateway.
S&F State | Description |
---|---|
No profile defined | No S&F profiles have been defined. S&F is disabled. |
Standby | Nothing to store and nothing to forward. This is the usual S&F State when the TR50 connection's Status is Connected and there are no actions stored or being forwarded. |
Ready to store | The TR50 connection's Status is Disconnected, and there is nothing stored. |
Storing | The TR50 connection's Status is
Disconnected, S&F capable actions
are being stored.
See Thing actions for S&F capable actions. |
Forwarding | The TR50 connection's Status is Connected, and actions have previously been stored. The actions are now being sent (forwarded) to the M2M Service. |
Ready to store - forced | Regardless of the TR50 connection's Status, a user has forced the S&F capable actions to go into storage, but no actions have yet been stored. |
Storing - forced | Regardless of the TR50 connection's Status, a user has forced the S&F capable actions to go into storage, and actions have been stored. |