OpenWetWare:Software/Projects/User count bug: Difference between revisions
(New page: Site stats are maintained in a table, "site_stats". The value of site_stats currently (11/16/2007 4:21) is 3360 Running a select command on the user table indicates the count is 3444. s...) |
No edit summary |
||
Line 2: | Line 2: | ||
The value of site_stats currently (11/16/2007 4:21) is 3360 | The value of site_stats currently (11/16/2007 4:21) is 3360 | ||
<correction: 3370 was the number. I checked the console log> | |||
Running a select command on the user table indicates the count is 3444. | Running a select command on the user table indicates the count is 3444. | ||
Line 29: | Line 30: | ||
This would indicate my assumption is wrong. One new row added to the table added 11 to the site_stats.ss_users column. | This would indicate my assumption is wrong. One new row added to the table added 11 to the site_stats.ss_users column. | ||
Based upon rechecking the value of ss_users (3370), the mod to update the user count was correct. | |||
I'm going to also reset the value of ss_users to the current row count of the user table (3445). | |||
I'll recheck the count in a few days to see if it's still correct. | |||
Bill |
Revision as of 14:55, 16 November 2007
Site stats are maintained in a table, "site_stats".
The value of site_stats currently (11/16/2007 4:21) is 3360 <correction: 3370 was the number. I checked the console log>
Running a select command on the user table indicates the count is 3444.
site_stats.ss_users is updated by an instantce of the SiteStatsUpdate class as follows:
$ssu - new SiteStatsUpdate( 0, 0, 0, 0, 1 );
$ssu->doUpdate();
The bit array corresponds to the following: $views; $edits; $good; $pages; $users;
The only call that invokes SiteStatsUpdate is SpecialUserlogin.php when a new user is created.
Since UMS does not use SpecialUserlogin.php to create users, the number may not be getting incremented correctly.
I added a call to SiteStatsUpdate for a new user from UMS. Upon rechecking the database after several more users were added, the numbers were as follows:
Database: ss_users = 3371 Rows in user table = 3445
This would indicate my assumption is wrong. One new row added to the table added 11 to the site_stats.ss_users column.
Based upon rechecking the value of ss_users (3370), the mod to update the user count was correct.
I'm going to also reset the value of ss_users to the current row count of the user table (3445).
I'll recheck the count in a few days to see if it's still correct.
Bill