Closed alecxandrys closed 3 years ago
Hi there! Thanks for reporting the issue. With withPresence
set to false, the Subscription should not be receiving those messages. Can you please share what channels are you subscribing to (so basically what is in _channelsList
) and how are you listening for those messages?
Are you doing subscription.messages
or subscription.presence
?
So I was actually able to reproduce the same behavior.
This is an interaction between the Presence system and Wildcard subscribes. To illustrate:
test.abc
and sends presence events there.test.*
.test.abc-pnpres
.test.*
matches with a channel test.abc-pnpres
(*
is interpreted as abc-pnpres
in this case) so the messages are received by the Client 2 as "normal" messages.Unfortunately this is the intended behavior and the SDK in this case behaves correctly. However there are possible solutions for this but they go outside of the scope of the SDK. My recommendation is to contact PubNub Support.
Good day, I use next code:
pubnub! .subscribe(channels: _channelsList.toSet(), withPresence: false)
After a while app catch a next message:
For some reason i have received message from Presence channel. It's provoke a enormous spam of Envelope in eventHandler.