Skip to content

On connect queued messages are sent before attaching channels #902

Description

@davyskiba

When a connection enters the connected state, queued messages are sent first, and channels are attached afterward. This behavior matches the in ConnectionManager.. It can lead to unexpected exceptions i.e. when queued presence leave message is sent before channel reattach like documented in this AAT issue.

Activity

  1. added
    bugSomething isn't working. It's clear that this does need to be fixed.
    on Jan 23, 2023
  2. sync-by-unito commented on Jan 23, 2023

    @sync-by-unito

    ➤ Automation for Jira commented:

    The link to the corresponding Jira issue is https://ably.atlassian.net/browse/SDK-3269

  3. paddybyers commented on Jan 23, 2023

    @paddybyers
    Member

    There should only be queued messages for channels that were attached at the time they were sent.

    If it's a reconnection that's a failed resume, then channels should be reattached before queued messages are sent.

  4. ikbalkaya commented on Jan 24, 2023

    @ikbalkaya
    Contributor

    @davyskiba Is it easy to replicate this in AAT repo 🤔 I'd like to test this against some changes I made recently.

  5. ikbalkaya commented on Jan 24, 2023

    @ikbalkaya
    Contributor

    So I had a run with the test locally against ably-java version with changes done #900
    the test passes and it fixes this issue. After confirmed collectively, we should close this issue

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working. It's clear that this does need to be fixed.

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions