Solved

userIsOnlineTimeWindow

Posted on 2006-11-22
16
939 Views
Last Modified: 2008-03-03
The help of an Expert is needed. As you can see on this page, a kind Expert has helped me to display a list of users presently online: http://www.experts-exchange.com/Programming/Programming_Languages/Dot_Net/ASP_DOT_NET/Q_22068663.html
However, it doesn't even matter if there's any activity from the user or not. After the 15 minutes has passed, as stipulated in userIsOnlineTimeWindow="15", the user is removed, regardless of whether or not he/she had any activity. And that really sucks, and this whole daggone Membership and User thing doesn't make any sense at all. So surely Microsoft wouldn't create a stupid thing like that; so I must be the one who's stupid here, and needs to be informed. Hence, I need an Expert to enlighten me. Please do.
0
Comment
Question by:John Account
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 8
  • 8
16 Comments
 
LVL 9

Expert Comment

by:kraffay
ID: 17999747
Online means the session for that user is active.  The user can log in and stare at the home page for 16 minutes, and he would be flagged as IsOnline = false.  His next hit at the site would reset the flag to true.
0
 

Author Comment

by:John Account
ID: 18000085
Well, that's the point. He's not staring at the screen for 16 minutes, or even for 3--during my tests--he's continually doing stuff, going to other pages in the site, clicking around. Doing things. And, still, after the 15 minutes has expired, so has his session--hence, it shows that he is not online.
0
 
LVL 9

Accepted Solution

by:
kraffay earned 500 total points
ID: 18000209
Hmmm...There's not much on this property, but one of my books does say that the computation of the time is made  by comparing the LastActivityDate property for the user to the current UTC time on the web server.  Is your web server time syncronized with a common time source?
0
Creating Instructional Tutorials  

For Any Use & On Any Platform

Contextual Guidance at the moment of need helps your employees/users adopt software o& achieve even the most complex tasks instantly. Boost knowledge retention, software adoption & employee engagement with easy solution.

 

Author Comment

by:John Account
ID: 18000564
Hmmmmmmmmmmnnnnnnn...you know what, I was doing it from Visual Studio. Maybe I should actually deploy the site to the server and try it that way and see if it's still not working.
0
 

Author Comment

by:John Account
ID: 18008552
I've deployed it to the web and it still doesn't work. After the allocated time--15 minutes--the user gets dropped from the online list, whether or not there's been any activity from him. So that property seems rather useless; but, surely, there must be something I'm missing here.
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18009998
Can you update the LastActivityDate during their session?  Can you take a look at that table and see if that field is getting changed?  If not, you may need to manually update it.
0
 

Author Comment

by:John Account
ID: 18010186
I ran a search for LastActivityDate. I don't have that property anywhere in my document. I'm telling you, kraffay--I don't know nothin' about this stuff! I have done very little in Asp.Net, and this is my first time using Memberships--but it's really cool--I love it, every time I learn something new with it, it's great. But there sure is a lot to learn. Whew.
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18020612
The LastActivityDate is in the aspnet_users table.  I think that if you update that field manually, perhaps at each postback, the IsOnline Funtionality may work.
0
 

Author Comment

by:John Account
ID: 18030115
Goodness gracious, so this whole feature is simply a database keeping record. Bummers. I thought it wouldn've been a server function keeping track of who's online, like in an array, for instance.

So this just adds more overhead to the database.
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18030196
Well, if you had to keep track of user activity for thousands of users in memory, that may be worse.
0
 

Author Comment

by:John Account
ID: 18031591
I guess there's no easy way then--easy as in easy with overhead, that is.

What if I have only a hundred users in the system, continually engaging in activity--that is, to say, that each user is continually hitting the database to insert records letting it know that he's still active. Whew...wouldn't that be a lot of overhead? Now, let's say the site escalated to a thousand simultaneous users. That would be quite a bit of activity on the database, wouldn't it? I mean, what would be an adaquate process and RAM to handle all that activity?
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18031726
Its a memory vs database overhead issue.  No, I don't think updating a database on a user event, perhaps on page_load is a big hit.  Managing state in a database is an accepted approach.  
0
 

Author Comment

by:John Account
ID: 18031837
So you don't think a thousand active users on a website would have a lot of overhead on the database utilizing Memberships like this? I have my mssql server 2005 on a 1.2 Ghz with 608 MB of RAM free on the system--and that's all that server is used for, the mssql server 2005. The website is on another server.
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18031918
You could write your own membership provider if its an issue.
0
 

Author Comment

by:John Account
ID: 18032074
Okay...this is getting way beyond the scope of the question, so this is where I say thanks. Thanks, Kraffay.
0
 
LVL 9

Expert Comment

by:kraffay
ID: 18032112
0

Featured Post

Online Training Solution

Drastically shorten your training time with WalkMe's advanced online training solution that Guides your trainees to action. Forget about retraining and skyrocket knowledge retention rates.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

User art_snob (http://www.experts-exchange.com/M_6114203.html) encountered strange behavior of Android Web browser on his Mobile Web site. It took a while to find the true cause. It happens so, that the Android Web browser (at least up to OS ver. 2.…
International Data Corporation (IDC) prognosticates that before the current the year gets over disbursing on IT framework products to be sent in cloud environs will be $37.1B.
In an interesting question (https://www.experts-exchange.com/questions/29008360/) here at Experts Exchange, a member asked how to split a single image into multiple images. The primary usage for this is to place many photographs on a flatbed scanner…

738 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question