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

Add topic to the message body #53

Merged

Conversation

ralphbean
Copy link
Member

This seems silly, but it is here to appease a codepath for
legacy fedmsg-based consumers, notably: datanommer.

This codepath is to blame: https://github.com/fedora-infra/fedmsg/blob/develop/fedmsg/consumers/__init__.py#L254-L259

There, if there is no topic in the body, then the fedmsg base class
that prepares the message before it is passed onto the application's
consume method tries to be helpful by "massaging" what is assumed
to be a stomp message from a non-fedmsg based system into
a fedmsg-friendly message by wrapping a msg: { envelope around it.

This causes problems reported in EXDSP-1169.

Ideally, that fedmsg codepath should be updated to do this more
carefully. Adding a topic to the greenwave message body like in
this commit should be harmless to other consumers and should succeed
in working around the legacy fedmsg framework.

This seems silly, but it is here to appease a codepath for
legacy fedmsg-based consumers, notably: datanommer.

This codepath is to blame: https://github.com/fedora-infra/fedmsg/blob/develop/fedmsg/consumers/__init__.py#L254-L259

There, if there is no topic in the body, then the fedmsg base class
that prepares the message before it is passed onto the application's
`consume` method tries to be helpful by "massaging" what is assumed
to be a stomp message from a non-fedmsg based system into
a fedmsg-friendly message by wrapping a `msg: {` envelope around it.

This causes problems reported in EXDSP-1169.

Ideally, that fedmsg codepath should be updated to do this more
carefully. Adding a topic to the greenwave message body like in
this commit should be harmless to other consumers and should succeed
in working around the legacy fedmsg framework.
@chuazhan
Copy link
Contributor

+1

@chuazhan chuazhan merged commit 86ddec1 into release-engineering:master Jun 17, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants