markham

  • Finally finished the Slideshow... phew!
  • Posts: 138
Re: Number of 'online users'
« Reply #15, on April 22nd, 2012, 08:10 PM »
Quote from Nao on April 22nd, 2012, 03:51 PM
Okay...

- I would also encourage getting rid of guest counting in the stats -- *except* in the Who's online / Info center areas where you can easily sort between guests and online members, and determine that 90% of the 'guests' are actually bots, etc... This kind of thing is interesting, but recording numbers on the long run is pointless because you can't know whether you got a bot swarm or simply an actual surge in interest.
As I have heavily mod'ed my sites, I can't honestly remember if a clean install of SMF distinguishes between spiders and guests in the "Who's online" or not. All I know is that spiders are clearly identified as such and are not counted in page views on my sites. But that said, you do make a valid point.
Quote
- I think that even if we don't start a session for guests, we should still record whatever page they're on and store it somewhere for the next 15 minutes (by IP.) I really like being able to know what a guest is doing... Not only that, but some people are adamant on knowing it, for security purposes. I'd suggest maybe only showing this data to admins, and showing it in a way that's different from the Who's online section -- for instance, we could store the query string and $_SERVER and show that in a subsection of the Who's online page, or something... Because bots will often try to reach URLs that you never considered, it's nice to be able to spot the oddities in there.
In other words, effectively a short-term "cookie" held on the server but as a database record? That actually might be far more accurate than the current system in which case I'm in favour.

lazyt

  • Code Idiot
  • I still haven't managed to break anything. But not for lack of trying:-) :-) :-)
  • Posts: 40
Re: Number of 'online users'
« Reply #16, on April 22nd, 2012, 08:43 PM »
Thank you Arantor, I had no idea the preview counted as a visit. Also the information on the cell towers cleared up several things for me.

Added: Back to the original topic. Please remove it. The number watchers will drive me up a wall yet.

Also if my idiot level questions annoy or take away from the discussion please remove or ignore them. It won't bother me at all.

Cryotech

  • Posts: 16
Re: Number of 'online users'
« Reply #17, on April 23rd, 2012, 08:15 AM »Last edited on April 23rd, 2012, 08:33 AM
Too be honest, I never really used that to determine user activity. I've always used the server's logging system because it's more accurate and contains more information.

I own a couple of sites, one of which receives nearly 2,000,000 unique hits a month with a forum. On any given day there could be well over 500 "users" playing around in the forum playing games, posting, reading what have you. Out of those nearly 1/4 to 1/2 will be listed as "Guest" and there many times this number is significantly inaccurate.

I wouldn't care one way or another but removing it will increase load time due to there not being queries being made for guests which tend to be bots anyways.

@ Arantor - I realize it can be hard, but don't take it personal bud. You have more peeps rooting you on then you realize. So here's a pint on me (or your choice of chillaxing beverage) and a steak. If you're a vegetarian, make it a carrot :D.

live627

  • Should five per cent appear too small / Be thankful I don't take it all / 'Cause I'm the taxman, yeah I'm the taxman
  • Posts: 1,670
A confident man keeps quiet.whereas a frightened man keeps talking, hiding his fear.

oOo--STAR--oOo

  • @Arantor Our greatest weakness lies in giving up. The most certain way to succeed is always to try just one more time
  • Posts: 43
Re: Number of 'online users'
« Reply #19, on April 23rd, 2012, 09:58 AM »
Hey Arantor,

I would like to apologise as I can get a little carried away.
We are all competitive in life and I guess I got carried away in my statements.

So for that I am sorry as I didn't mean to cause any offence.
I'm a very defensive person myself and I can take what people say to me personally.

Cheer up, I like what you are doing with wedge and your thoughts on giving up are not worth contemplating.
You should always finish what you start, regardless of the obstacles that step in your way.
No point in starting if you are thinking of not finishing.
Its part of the challenge just like life its self.
If you don't finish then you are only going to let yourself down. You know that.

Your strong minded and always like to defend your point. That's a quality a lot of people lack.
The way I think about things is like this. If you agree with everyone all the time, then nothing will progress.
The part of disagreeing allows you to challenge what you do agree with.
Didn't mean to offend you or cause you aggravation.

Peace,
Star.




Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Number of 'online users'
« Reply #20, on April 25th, 2012, 06:16 PM »
Quote
Cheer up, I like what you are doing with wedge and your thoughts on giving up are not worth contemplating.
They certainly are. It's because of people like you that I have spent the past 3 days avoiding this forum, with pretty much all desire to contribute removed.
Quote
Also if my idiot level questions annoy or take away from the discussion please remove or ignore them. It won't bother me at all.
Asking questions is great, because it pushes me to explain why something is or is not so, which means everyone benefits through a better understanding (and it can often cause me to look at an issue differently, which is also a good thing)

I won't remove posts or prevent people from expressing an opinion. Where it gets frustrating is not because people don't understand, but where people think they do and keep perpetuating incorrect information and won't be corrected.

Anyway.
Quote
In other words, effectively a short-term "cookie" held on the server but as a database record? That actually might be far more accurate than the current system in which case I'm in favour.
Um. Same thing as what's there currently.

I see that people are getting a bit confused.

What is a guest?

A guest is a user who is not signed in.

What's the difference between a user who is signed in and who isn't?

The type of cookie they have going back and forth, and a number set in a couple of places.

Wait, what?

All users, guests and members, transmit session information back and forth. The session identifies that the current page is being requested as part of a series of requests that a given 'unique user' is making. This session may be passed via URL, or more commonly passed back and forth by cookie.

Guests get one type of cookie, the PHPSESSID cookie. Members get another type of cookie, WedgeCookieXXX[1]. Both cookies principally carry the session id back to the forum.

By counting the number of active sessions, we can tell how many users are online. Specifically, we check how many sessions are members, and which of those members are unique (e.g. one member having two sessions is counted once), and then we check how many guest sessions there are.

There is where it starts to be a problem: the number of guest sessions is only tenuously connected to the number of actual people browsing the forum at any one time. Search engines inflate that number, as do previews, certain kinds of pre-fetch/web performance optimisation plugins, and other things.

Now, sessions are stored and tracked in two different database tables. The exact structure of these does not matter for this purpose, other than the fact that we have a session identifier being passed back and forth to attempt to uniquely identify how many users there are.

OK, I understand, so what exactly are you proposing?

I'm suggesting to stop tracking sessions for guests at all. Everyone else who fixated on certain things missed the point.

Not tracking sessions for guests has a lot of consequences.

There are some quick things that sum it up:
* Performance grows, by a non trivial amount. Bandwidth is also saved both ways on every page for guests.
* We get SEO benefits by never having to deal with PHPSESSID cookies again. This also has consequences for the EU cookie law, of course.

There are some huge things that may or may not be a problem.

* We lose the ability to see how many 'guests' or 'search engines' are online right now. This means we lose the ability to display this not-particular-accurate number to users, or to show it historically. For users who don't have much activity, this is actually probably a boost, not a problem, because it's often better to say nothing than to show a figure of how quiet things are (certainly one forum I have been associated with recently has this exact problem)

It does also discourage people who want to fake the number to show it to people.

* We lose the ability to see what guests (and search engines) are doing right now. I'm not convinced this is a particularly useful piece of information, seeing what different things people are looking at - because it's only what people are looking at right now. It's just a snapshot of the last x minutes, not a rolling figure, nor a historical study. It's like trying to analyse traffic patterns on a motorway from a single photo: it gives you an idea at that precise moment in time, but that may be completely wrong, or it may be completely spot-on, though more likely wrong.

Now, before we got bogged down in splitting hairs over untrackably small quantities of resource, the requests are logged on any competent host (or turned off if it is not desired) - that log is processable via awstats or other analytics packages. Those who feel very strongly about it will use Google Analytics or similar anyway, and those who don't almost certainly won't care either way.

All in all, in my view, tracking what guests are doing right now is an unnecessary duplication of work, at the wrong level.

For those of you who do actively chase that stat, or actively peruse Who's Online, what is it you're looking for? What is it you're hoping to achieve, exactly, by studying Who's Online for guests? (I want to know what you hope to get out of it, and whether you actually get that information. Are there any alternatives to that information?)

Note that this, if implemented, would also play into the 'number of people currently viewing a topic' or 'viewing a board', since this is something that is pretty much all or nothing to implement.
 1. The number here is determined when first creating the forum. Do not worry about how it is made, it doesn't matter for this discussion.
When we unite against a common enemy that attacks our ethos, it nurtures group solidarity. Trolls are sensational, yes, but we keep everyone honest. | Game Memorial

PantsManUK

  • [me=PantsManUK]would dearly love to dump SMF 1.X at this juncture...[/me]
  • Posts: 174
Re: Number of 'online users'
« Reply #21, on April 25th, 2012, 06:30 PM »
Personally? Drop the session for guests, it doesn't hurt me in the least... I have GA and Awstats, I get far better info from them than I do from Who's Online (which on SMF at least is "stale" from the moment it's displayed...)

Out of interest, and somewhat OT, could the associated DB table for Who's Online be treated as a "pipe" (max of say 10 rows, when number 11 arrives, it pushes number 1 off the table)? I would think that doing so, possibly using triggers/stored procedures, would give performance benefits, especially on forums with large user populations.
« What is this thing you hoomans call "Facebook"? »

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Number of 'online users'
« Reply #22, on April 25th, 2012, 06:35 PM »
To answer your question, no, it couldn't because the table needs to contain everyone that's online at present, whether the online log is populated with lots of detail or not. (It has other uses than simply being the list of who is currently online at present)

PantsManUK

  • [me=PantsManUK]would dearly love to dump SMF 1.X at this juncture...[/me]
  • Posts: 174
Re: Number of 'online users'
« Reply #23, on April 25th, 2012, 06:37 PM »
Thanks for the explanation. Makes sense that it's used for other things than who's on the site right this second...

nend

  • When is a theme, no longer what it was when installed?
  • Posts: 165
Re: Number of 'online users'
« Reply #24, on April 25th, 2012, 06:55 PM »
How about where it says "so and so is viewing this topic"?

Doesn't really matter though, I have a board where I removed all that stuff because it didn't really flow with the site. If someone wants it later though maybe a aftermarket plugin or such? You know you are going to get people that still want that feature, I can care less though.

In a way though, are you copying me, lol, jk.

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Number of 'online users'
« Reply #25, on April 25th, 2012, 06:58 PM »
Yup, I actually mentioned that one, since the same log is used there too, and it would end up being limited to online users only.

The problem with it being an aftermarket plugin is that it is core functionality in Wedge with cookie handling and I suspect it would be a mess to make a plugin out of. But it's certainly feasible, I guess. You're right that people will want that, even though they're chasing something that's inaccurate and unhelpful (IMO)

I'm not intentionally copying you, but I find it interesting that we've looked at the same things - though with slightly different reasons behind it.

nend

  • When is a theme, no longer what it was when installed?
  • Posts: 165
Re: Number of 'online users'
« Reply #26, on April 25th, 2012, 07:04 PM »
Is there going to be a option to see what friends are online? At least this, you can take everything else away. :D

Arantor

  • As powerful as possible, as complex as necessary.
  • Posts: 14,278
Re: Number of 'online users'
« Reply #27, on April 25th, 2012, 07:05 PM »
There isn't at present but I suppose it could be; since you need to be signed in, and they need to be signed in, between them it's fairly trivial to do. It will probably be more useful than seeing what guests are online, actually ;)

godboko71

  • Fence accomplished!
  • Hello
  • Posts: 361
Re: Number of 'online users'
« Reply #28, on April 25th, 2012, 08:33 PM »
I care what signed in users are doing it is semi useful... to users to know they aren't alone or they are but as an admin none of it matters because I can use awstats and or other software to track everyone. See what pages get the most traffic and the like. So TBH it is nothing I need so take out guest tracking.
Thank you,
Boko

Nao

  • Dadman with a boy
  • Posts: 16,082
Re: Number of 'online users'
« Reply #29, on April 26th, 2012, 04:53 PM »
Quote from Arantor on April 25th, 2012, 07:05 PM
There isn't at present but I suppose it could be; since you need to be signed in, and they need to be signed in, between them it's fairly trivial to do. It will probably be more useful than seeing what guests are online, actually ;)
Indeed.
Heck, when we implement custom groups, friend lists will suddenly become trendier to use -- if only because you'll be able to specify your own 'custom' colors for them, mesays.