Open bhaugen opened 8 years ago
Did you end up fixing this? Is there a custom cache someplace or would this involve hacking django or the server settings? Where can the deleted events get? Show up in querysets? Primary keys referenced by other objects?
This is about CachedEventSummary https://github.com/valnet/valuenetwork/blob/master/valuenetwork/valueaccounting/models.py#L11664
I rebuilt the cache using the summarize_all_events class method using shell_plus on the server, which I have done a few times. Have not rethunk the cache.
This is used for the diagrams on collective agent pages, because otherwise they were too slow. Occasionally people have seen errors in the diagrams. That's when I have rebuilt the cache
Are they sitting in the cache indefinitely? It seems like that would compromise the integrity of those diagrams, but as long as the primary keys never show up in, say, the queryset of a form field that is getting posted back and saved, it should have a limited impact on the integrity of the whole system.
CachedEventSummary is just another table in the database. It is not like memcache etc.
Deleted contributions are not getting removed from the cache. This might be deleted via admin, or it might be in general.
Short term: restart the cache. Medium term: rethink the cache.