Wednesday, December 9, 2015

Re: get all current active connected users

On Wednesday, 9 December 2015 12:55:22 UTC, Jani Tiainen wrote:
This is really problematic domain since as you know, Django works on HTTP request-response cycle. After cycle is finished there is absolutely no way to know "who is logged on".

So first you have to determine factors that make up "currently active user". Then you have to track that information somehow and after that it's possible to gather a list of active/inactive users.

Users have a last_login field so you could easily say "users who have logged in in the last 24 hours" or whatever. 

--
You received this message because you are subscribed to the Google Groups "Django users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to django-users+unsubscribe@googlegroups.com.
To post to this group, send email to django-users@googlegroups.com.
Visit this group at http://groups.google.com/group/django-users.
To view this discussion on the web visit https://groups.google.com/d/msgid/django-users/7c5f0620-c094-4667-b474-82a23f432fa1%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

No comments:

Post a Comment