Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix circular ChainActivityMessage again again #680

Merged
merged 2 commits into from
Apr 7, 2024

Conversation

BentiGorlich
Copy link
Member

@BentiGorlich BentiGorlich commented Apr 7, 2024

when we get a like message which has url A as the "object" (or as the "id" of the "object") and the returned json has a different url B as the "id", then we went to a circular message, because the ChainActivityHandler would create the object with id B, but Like-, Dislike- and AnnounceHandler would search for an object with id A.

If that occurs now, a warning will be logged and the Like-, Dislike- and AnnounceMessage that will be dispatched by the ChainActivityHandler will be adjusted to use the id that is actually in the json response from the url

Closes #668

when we get a like message which has url A as the "object" (or as the "id" of the "object") and the returned json has a different url B as the "id", then we went to a circular message, because the ChainActivityHandler would create the object with id B, but Like-, Dislike- and AnnounceHandler would search for an object with id A.

If that occurs now, a warning will be logged and the Like-, Dislike- and AnnounceMessage that will be dispatched by the ChainActivityHandler will be adjusted to use the id that is actually in the json response from the url
@BentiGorlich BentiGorlich added bug Something isn't working activitypub ActivityPub related issues backend Backend related issues and pull requests labels Apr 7, 2024
@BentiGorlich BentiGorlich self-assigned this Apr 7, 2024
Copy link
Member

@nobodyatroot nobodyatroot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't have an active circular message situation to test this on, but it makes sense if this is another cause.

@BentiGorlich
Copy link
Member Author

You could test it by publishing a message via rabbit mq management

@nobodyatroot
Copy link
Member

You could test it by publishing a message via rabbit mq management

Ok, yep... thanks! lgtm

@BentiGorlich BentiGorlich merged commit e7f6758 into main Apr 7, 2024
7 checks passed
@BentiGorlich BentiGorlich deleted the fix/circular-message-again-again branch April 7, 2024 14:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
activitypub ActivityPub related issues backend Backend related issues and pull requests bug Something isn't working
Projects
None yet
Development

Successfully merging this pull request may close these issues.

ChainActivityMessage infinite queue issue
2 participants