unable to receive messages when client is reloaded from pubsub

13 views
Skip to first unread message

Sanjeev Kumar

unread,
Dec 25, 2018, 8:56:37 AM12/25/18
to Redis DB
When I refresh the page intentionally the new client Id is created So I can't listen to the channels which is subscribed by the old client Id, which is done during the login. Do I need to subscribe with the new client or is there any other method to keep the same client?

hva...@gmail.com

unread,
Dec 25, 2018, 2:56:15 PM12/25/18
to Redis DB
The answer to your question comes from the language you are using for your web application and it's run-time capabilities.  Some languages make it easy to keep a Redis client running and re-connect the browser to the running Redis client after a simple page refresh.  Some languages make it extremely difficult.  PHP is one of the latter.  You haven't described your web app's language/run-time so it would be impossible for anyone to give you more details on how to do it.

And this has nothing to do with the Redis client or server, so even knowing your language this group won't be as good a place for this question as the discussion groups for the language you're using.

Ajay Thakur

unread,
Dec 26, 2018, 12:55:00 AM12/26/18
to to: Redis DB
HI Sanjeev,
When new client connects then it has to subscribe for notifications.
Server has not way to know to carry forward those subscriptions.

Thanks
Ajay

--
You received this message because you are subscribed to the Google Groups "Redis DB" group.
To unsubscribe from this group and stop receiving emails from it, send an email to redis-db+u...@googlegroups.com.
To post to this group, send email to redi...@googlegroups.com.
Visit this group at https://groups.google.com/group/redis-db.
For more options, visit https://groups.google.com/d/optout.


--
B Good. !

Sanjeev Kumar

unread,
Dec 26, 2018, 1:28:13 AM12/26/18
to Redis DB
Language for the backend is node js and can you help me which of the languages keep a Redis client running and re-connect the browser to the running Redis client after a simple page refresh. 

Sanjeev Kumar

unread,
Dec 26, 2018, 1:30:43 AM12/26/18
to Redis DB
but this cannot be possible when user refreshes right . I am asking is there any chance keeping the old client running  rather than creating the new client
Reply all
Reply to author
Forward
0 new messages