WIP: Cache invalidation by entity.

#6043 
WIP
in that case you can always set to lowercase, and do only a single check.