-
Notifications
You must be signed in to change notification settings - Fork 43
Description
When handling a failed resume in accordance with RTN15c3 (https://github.com/ably/specification/blob/ee511f8a62e3e09cdd2ce50fadddb2d66f2ebaa3/textile/features.textile#RTN15c3), the ConnectionManager processes outstanding queued messages via `ConnectionManager.queuedMessages (
| addPendingMessagesToQueuedMessages(true); |
However, these messages instead need to be requeued at the Channel level, so that they are correctly processed relative to the re-attach that happens. (Currently, replayed presence messages are reattempted before the channel attach has completed.)
Normal Messages need to be removed from ConnectionManager.queuedMessages and ConnectionManager.pendingMessages and put back into ChannelBase.queuedMessages (
| queuedMessages = new ArrayList<QueuedMessage>(); |
Presence messages need to be removed from ConnectionManager.queuedMessages and ConnectionManager.pendingMessages and put back into Presence.pendingPresence (
| private final Map<String, QueuedPresence> pendingPresence = new HashMap<String, QueuedPresence>(); |