invalidateById - invalidates the given key. If the key is
for a specific cache entry, then only that object is
invalidated. If the key is for a dependency id, then
all objects that share that dependency id will be
key - the key which will be invalidated
waitOnInvalidation - True indicates that this method should
not return until the invalidations have taken effect on all caches.
False indicates that the invalidations will be queued for later