openid/sharedsignals

Enhancement: StreamConfig Reset Parameters

independentid opened this issue · 0 comments

Following on to Issue #107, there are times when a receiver may wish to reset a stream to a specific date or JTI value.

Use Case 1:

Bootstrapping a receiver: A receiver receives a backup of data and instantiates itself as of the date of the backup. For example a database or SCIM directory node is loaded from a backup. The desire is to set the stream's starting date to the date of the backup.

Use Case 2:
After a data loss or other failure at the receiver, the receiver would like to roll back the stream to a specific JTI number or date.

Use Case 3:
A new stream is created. The stream to contain events if available as of a specific date other than stream creation time.

Proposal:

The following two Stream Configuration parameters may be provided via POST, PUT or PATCH or retrieved using GET.

Attributes:

  • [resetDate] The date to which the stream is to be (or was) reset in RFC 3339 format. If available, any event on or after the date will be transferred in the stream.
  • [resetJti] A string value containing a SET JTI value to reset the stream to. If available, the event matching or since should be transferred.

In the event that the transmitter's event storage does not go back to the date or JTI requested, the stream shall be reset to the oldest event available.