According to the documentation, you can retry operations by registering them to the client again. I'm doing this on Sitecore 9.0.2.
https://doc.sitecore.com/developers/90/sitecore-experience-platform/en/handling-exceptions.html
In the following example, an operation is retried after xConnect returned a XdbUnavailableException, indicating that the xConnect service was unavailable:
catch (XdbUnavailableException ex) { // Get any operations that failed var operations = ex.GetOperations(client) .Where(x => x.Status == XdbOperationStatus.Failed); foreach (var ops in operations) { client.RegisterOperation(ops); } client.SubmitAsync(); }
Unfortunately, the code example on the documentation does not work. XdbUnavailableException does not contain a GetOperations
method.
What should be implemented on an XdbUnavailableException?