redis-om-dotnet
redis-om-dotnet copied to clipboard
JSON.SET with NX/XX
Normally Redis has support to JSON.SET key path value [NX | XX] command.
I think this have to implement the dotnet library. We use raw command now but it is not best approach. InsertIfNotExist or InsertIfExist native support will be good. This result could return bool.
true if executed correctly, or false if the specified NX or XX conditions were not met.
Conditions NX - only set the key if it does not already exist XX - only set the key if it already exists
I will work on it soon.
@shacharPash Not sure if it is possible, can we also add: AddorUpdate ? this would be great since it would take care of all the checks
@shacharPash Not sure if it is possible, can we also add: AddorUpdate ? this would be great since it would take care of all the checks
Wouldn't AddOrUpdate() effectively be the same as an Insert()... or are you think of this more for the statefull side where it would replace or patch on the request?
No, i've created https://github.com/redis/redis-om-dotnet/issues/212