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: use channel.address instead of id #582

Merged
merged 4 commits into from
Nov 22, 2023

Conversation

Souvikns
Copy link
Member

Description

This small fix updates channel.address() instead of channel.id() in mqtt.

Related issue(s)

Fixes #581

@coveralls
Copy link

Pull Request Test Coverage Report for Build 6904144969

  • 0 of 0 changed or added relevant lines in 0 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage remained the same at 67.034%

Totals Coverage Status
Change from base Build 6879694135: 0.0%
Covered Lines: 359
Relevant Lines: 472

💛 - Coveralls

Copy link
Member

@KhudaDad414 KhudaDad414 left a comment

Choose a reason for hiding this comment

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

Hey @Souvikns , can you also make sure that when we receive a message, we pass the channel name to the message when it is created not channel address, since glee will verify the channel name.

@Souvikns
Copy link
Member Author

Yeah Looks like we are doing it
Screenshot 2023-11-17 at 6 36 23 PM

fmvilas
fmvilas previously approved these changes Nov 20, 2023
Copy link
Member

@KhudaDad414 KhudaDad414 left a comment

Choose a reason for hiding this comment

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

When we receive a message and create the message here:

    return new GleeMessage({
      payload: packet.payload,
      headers,
      channel: packet.topic,
    })
  }

we use the channel address (which is topic) but glee expects to receive the channel id.
I mean we should change this code to create the message with the channel id not channel address here.
If you run the current code with an example, it will fail.

Copy link

Kudos, SonarCloud Quality Gate passed!    Quality Gate passed

Bug A 0 Bugs
Vulnerability A 0 Vulnerabilities
Security Hotspot A 0 Security Hotspots
Code Smell A 0 Code Smells

No Coverage information No Coverage information
0.1% 0.1% Duplication

Copy link
Member

@KhudaDad414 KhudaDad414 left a comment

Choose a reason for hiding this comment

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

LGTM!

@Souvikns
Copy link
Member Author

/rtm

@asyncapi-bot asyncapi-bot merged commit 9bc2de0 into asyncapi:master Nov 22, 2023
12 checks passed
@asyncapi-bot
Copy link
Contributor

🎉 This PR is included in version 0.30.1 🎉

The release is available on:

Your semantic-release bot 📦🚀

@derberg
Copy link
Member

derberg commented Nov 22, 2023

@Souvikns you will need to manually update CLI -> https://github.com/asyncapi/cli/blob/master/assets/create-glee-app/templates/tutorial/package.json#L19 as the bumper that we use, is capable to updating just one dependency in given repo, and first on the list that it takes into account is the default one only

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Incorrect MQTT Topic Subscription - Uses channel.id() Instead of channel.address()
6 participants