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

refactor(deskop): session expriy default to 7200 #1744

Merged
merged 1 commit into from
Sep 2, 2024
Merged

Conversation

ysfscream
Copy link
Member

PR Checklist

If you have any questions, you can refer to the Contributing Guide

What is the current behavior?

Currently, for MQTT v5 with a clean start set to false, the Session Expiry Interval is set to never expire by default. This can lead to persistent connections that may unnecessarily consume resources, especially in Serverless environments where it can affect billing.

Issue Number

Example: #123

What is the new behavior?

This PR proposes to change the default Session Expiry Interval from never expire to 7200 seconds (2 hours, keep with EMQX default config) when using MQTT v5 with clean start set to false. This change aims to balance connection persistence with resource management.

image

Proposed changes:

  • Modify the default Session Expiry Interval to 7200 seconds for MQTT v5 when clean start is false.
  • Update relevant documentation to reflect this change.

Does this PR introduce a breaking change?

  • Yes
  • No

This change may affect existing connections that rely on indefinite session persistence.

Specific Instructions

  1. Update the handleClean method or equivalent to set the new default value.
  2. Test thoroughly with various MQTT v5 scenarios to ensure compatibility.
  3. Update user documentation to explain the new default behavior an

@ysfscream ysfscream added enhancement New feature or request refactor Refactor code or architecture desktop MQTTX Desktop labels Aug 30, 2024
@ysfscream ysfscream added this to the v1.11.0 milestone Aug 30, 2024
@ysfscream ysfscream requested a review from Red-Asuka August 30, 2024 08:20
@ysfscream ysfscream self-assigned this Aug 30, 2024
@Red-Asuka Red-Asuka merged commit 3e67f6e into main Sep 2, 2024
1 check passed
@Red-Asuka Red-Asuka deleted the ysf/desktop branch September 2, 2024 01:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
desktop MQTTX Desktop enhancement New feature or request refactor Refactor code or architecture
Projects
Status: Done
Development

Successfully merging this pull request may close these issues.

2 participants