cs3org / OCM-API

OpenCloudMesh API
38 stars 11 forks source link

Are notifications allowed to have side-effects? #46

Closed michielbdejong closed 9 months ago

michielbdejong commented 3 years ago

A little philosophical question I ran into while writing the test suite:

When Alice shares a resource with Bob, she cannot share it again. If she tries to share it a second time, her GUI will warn her 'Bob already has access'. But if Bob sent back a notification like SHARE_DECLINED or SHARE_REMOVED the that will in practice usually have the side-effect that Alice can share the resource with Bob again.

This suggests that either sharing with someone should be idempotent, or the notifications and their side-effects should be standardised.

michielbdejong commented 1 year ago

@glpatcern since we're now talking about tagging a v2.0 at some point, maybe this is one thing to be aware of. In any case I think we can write down the spec in more detail than just the Swagger file with comments we have now (more like an IETF Internet Draft or a W3C spec)

glpatcern commented 1 year ago

Agreed. I started to tag a few issues I believe are worth discussing, and I was hesitant on this one - where my current understanding is that yes we do allow (and we need to) for side-effects though they are non standardized.

michielbdejong commented 1 year ago

Yeah, we can at least document them as 'MAY' behaviours.