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

Delete existing will message on client connect #351

Merged
merged 3 commits into from
Jan 15, 2020
Merged

Delete existing will message on client connect #351

merged 3 commits into from
Jan 15, 2020

Conversation

robertsLando
Copy link
Member

@robertsLando
Copy link
Member Author

I also would suggest to keep just 1 retained message in db foreach client. Actually mondodb allows multiple will messages to be stored for the same clientid, In putWill function there should be a findAndUpdate with upsert true

Copy link
Collaborator

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

Would you mind to add a unit test for this feature?

lib/handlers/connect.js Outdated Show resolved Hide resolved
@robertsLando
Copy link
Member Author

@mcollina done

Copy link
Collaborator

@mcollina mcollina left a comment

Choose a reason for hiding this comment

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

lgtm

@mcollina mcollina merged commit ac4bc27 into moscajs:master Jan 15, 2020
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