Like Caches
Last modified by Eleni Cojocariu on 2026/08/12 16:21
Content
Explanation
Two caches sit in front of Solr: one holds the like count of an entity, the other whether a given user liked a given entity. Both are LRU caches, sized by the cache capacity of the Like preferences.
The API keeps them in step with the store: liking or unliking an entity drops the entries of that entity, deleting a document drops its entries, and deleting a wiki or a user empties both caches.
Writing likes straight through the Ratings API bypasses all of it and leaves stale counts behind, so go through the Like Java API instead.
FAQ
How do I repair a like count that went stale?
Call clearCache(target) for one entity, or clearCache() for everything, on the Like Java API.