code: private CompletableFuture<Void> handleAttributeException(CompletableFuture<Void> future) {
          return Futures.exceptionallyExpecting(
                  future,
                  ex -> (ex instanceof StreamSegmentSealedException && this.metadata.isSealedInStorage())
                          || ((ex instanceof StreamSegmentNotExistsException || ex instanceof StreamSegmentMergedException)
                          && (this.metadata.isMerged() || this.metadata.isDeleted())),
                  null);
      }
docs: Handles expected Attribute-related exceptions. Since the attribute index is a separate segment from the main one,
  it is highly likely that it may get temporarily out of sync with the main one, thus causing spurious StreamSegmentSealedExceptions
  or StreamSegmentNotExistsExceptions. If we get either of those, and they are consistent with our current state, the
  we can safely ignore them; otherwise we should be rethrowing them.