netwind
01-09-2007, 07:29 PM
I found this comments in code in file includes/session.php :
// if this line is removed (say to be replaced by a cron job, you will need to change all of the 'online'
// status indicators as they use $userinfo['lastactivity'] to determine if a user is online which relies
// on this to be updated in real time.
$DB_site->shutdown_query("
UPDATE " . TABLE_PREFIX . "user
SET lastactivity = " . TIMENOW . "
WHERE userid = $bbuserinfo[userid]
", 'lastvisit');
But not found somebody who use cron script for lastactivity update.
Remove this query can provide more scalability and reduce one query.
If i don't need instant showing online users and it's locations,
is it safe remove this query ?
Does worked cron job example exists ?
// if this line is removed (say to be replaced by a cron job, you will need to change all of the 'online'
// status indicators as they use $userinfo['lastactivity'] to determine if a user is online which relies
// on this to be updated in real time.
$DB_site->shutdown_query("
UPDATE " . TABLE_PREFIX . "user
SET lastactivity = " . TIMENOW . "
WHERE userid = $bbuserinfo[userid]
", 'lastvisit');
But not found somebody who use cron script for lastactivity update.
Remove this query can provide more scalability and reduce one query.
If i don't need instant showing online users and it's locations,
is it safe remove this query ?
Does worked cron job example exists ?