Perhaps, but then what is the point of taking the CAS as a parameter? I’ve obviously been able to easily work around this issue in my code (implementing my own “KeyExists()” in my code, which then calls Observe and interprets the response as I described. But, again, no point in taking CAS if that’s not the expected behavior.
The CAS parameter on the observe method (which is used internally) is needed for PersistTo/ReplicateTo checks, so this is probably the reason why it’s exposed like this. That said, I don’t know the .NET SDK that much so I can say if it is expected to be used by the public and if it’s a bug or intended.
To be honest, I am not sure why that method takes a CAS value. I would think the behavior should simply be to check if the key exists, not that it exists and then value hasn’t changed. That being said, it’s using Observe internally which is probably the reason.
Also, the server should be validating the CAS value passed in, not the client. If that method is not honoring the CAS its probably an implementation bug somewhere in the client.