Detecting duplicate activities
-
How does one go about detecting duplicate activities, and what is the best practice for senders?
I ask because following a hashtag served by
relay.fedi.buzzresponds with anAcceptwith idhttps://relay.fedi.buzz/activity/accept/{actor}/{requesterInbox}Because that URL does not have a random/time-based component, an unfollow followed by a refollow will lead to an
Acceptwith the exact sameid.In NodeBB's case, it detects this as "already seen" and silently drops it.
I could ask @astro@c3d2.social to add a timestamp in the ID, but I was wondering if my duplicate detection strategy was naive <img class="not-responsive emoji" src="https://activitypub.space/assets/plugins/nodebb-plugin-emoji/emoji/android/1f604.png?v=4459463b5a0" title="
" /> -
-
@silverpill@mitra.social okay, but in the case of the accept, the body is identical, but is only different because of where it sits relative to other activities (e.g. it came after an unfollow therefore it is relevant again)
It makes me think back to why I added dupe detection in the first place. Likely it was to handle Delete spam, but I can't remember anymore.
-
PieFed activities each have a unique ID, with a guid in it.
-
@silverpill@mitra.social good point! The embedded object likely is unique.
Ciao! Sembra che tu sia interessato a questa conversazione, ma non hai ancora un account.
Stanco di dover scorrere gli stessi post a ogni visita? Quando registri un account, tornerai sempre esattamente dove eri rimasto e potrai scegliere di essere avvisato delle nuove risposte (tramite email o notifica push). Potrai anche salvare segnalibri e votare i post per mostrare il tuo apprezzamento agli altri membri della comunità.
Con il tuo contributo, questo post potrebbe essere ancora migliore 💗
Registrati Accedi
Citiverse è un progetto che si basa su NodeBB ed è federato! | Categorie federate | Chat | 📱 Installa web app o APK | 🧡 Donazioni | Privacy Policy