Succeed a RelationshipAttribute and notify peer
This use case allows the owner to update a RelationshipAttribute, while automatically handling the coherent versioning at both your and your peer’s side.
Succeeding an OwnRelationshipAttribute, a new OwnRelationshipAttribute with the updated content will be created at your side.
In its succeeds property it links to the predecessing version, which in turn is also updated and links to the newly created version in its succeededBy property.
Thus, a doubly linked list is established, ensuring every version to have not more that one predecessor or successor.
Once the succession at your side is completed, a Notification is sent automatically to your peer.
It triggers the succession of their PeerRelationshipAttribute in the same manner as described above, such that both your succession chains match.
Parameters
predecessorIdis theidof the OwnRelationshipAttribute.- The updated
successorContentlimited to thevalueproperty of a RelationshipAttribute that may be changed by a succession.
On Success
- The response returns a
predecessorand asuccessorOwnRelationshipAttribute, as well as thenotificationIdof the Notification sent to the peer. - The
predecessoris an updated version of the OwnRelationshipAttribute, having thesucceededByfield set to theidof thesuccessor. - The
successoris a new OwnRelationshipAttribute version with the specifiedsuccessorContent. Itssucceedsproperty links to thepredecessor.
On Failure
- The response cannot be created if the
predecessorIddoesn’t belong to a valid OwnRelationshipAttribute. - The response cannot be created if the OwnRelationshipAttribute belonging to the
predecessorIdalready has a successor. - The response cannot be created if the OwnRelationshipAttribute belonging to the
predecessorIdhas adeletionInfowith"DeletedByRecipient"asdeletionInfo.deletionStatus. - The response cannot be created if the parameters are malformed.