-
Enhancement
-
Resolution: Done
-
Major
-
14.0.0.Final
-
None
Today if a remove is performed on the cache and the value is not present it will still continue processing as if it is removing something. This can cause unneeded strain on the cache. Things such as clustered replication and store updates are still processed when they wouldn't need to be. Listeners are notified of a remove that does not have a value.
We should be able to instead ignore that remove operation and just return early on the primary without contacting any other nodes, stores or listeners.
This will most likely break a lot of tests and the biggest change will be notifications in embedded will no longer be raised. Technically remote events will also no longer be raised, but that was changed just recently in https://issues.redhat.com/browse/ISPN-15211 since listeners had no way to ignore an old existing value.
Also this change should only target nontx caches first as it should be simpler and tx caches have additional things to worry about such as retaining locks for a remove command and possibly other things.