by surferbayarea · 14y ago · 0 comments
So the way facebook implements a delete of any activity(status post/like/comment) is that the owner stops seeing it but everyone else keeps seeing it. That is simply the most retarded delete implementation ever!
cache invalidation is hard.
This is not hard.
Just send a new message, exactly as you would post an original item/comment/etc, but have some special text/field in there that says "please ignore the previous message". The UI would then hide the previous message.
eg
COMMENT: {id:9374758, from:"mibbitier", data:"I hate you all!"}
COMMENT: {id:9374759, from:"mibbitier", data:"*IGNORE_MESSAGE_IN_UI* 9374758"}
Nothing whatsoever to do with infrastructure. Nothing to do with caches. Purely to do with the UI. Not rocket science.Granted, it's a poor way to do it, but it's better than nothing, and easier than trying to invalidate caches etc