Lobbying Again for Change to Account Page

Message boards : Number crunching : Lobbying Again for Change to Account Page
Message board moderation

To post messages, you must log in.

1 · 2 · Next

AuthorMessage
Cruncher-American Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor

Send message
Joined: 25 Mar 02
Posts: 1513
Credit: 370,893,186
RAC: 340
United States
Message 1059358 - Posted: 24 Dec 2010, 12:22:02 UTC

Like many folks here, I occasionally want to see the Pending Credit I have, and I almost never want to see the actual list of pending WUs. But the Account/Preferences page shows something like:

Total credit 15,670,448

Recent average credit 37,760.06

SETI@home classic workunits 18,594

SETI@home classic CPU time 103,828 hours

Pending credit View

Computers on this account View

Tasks View

And to get the total pending credit, one has to click "view", which causes a database access to get the list, and then uses b/w to send it to me.

Why can't the "Pending Credit" item just show the total, just as the lines above it do? And in fact, if i really want to see the Pendings one-by-one, I can use the Tasks "view" to get to all my Pending WUs anyway.

Any objections and/or support out there?

Bueller?
ID: 1059358 · Report as offensive
xx
Volunteer tester

Send message
Joined: 23 May 99
Posts: 166
Credit: 3,450,910
RAC: 0
United States
Message 1059360 - Posted: 24 Dec 2010, 12:47:58 UTC

Sounds reasonable to me. It's annoying to have to scroll all the way down to the bottom of that list just to see the number, which is really all I wanted to see anyway.
ID: 1059360 · Report as offensive
Profile Frizz
Volunteer tester
Avatar

Send message
Joined: 17 May 99
Posts: 271
Credit: 5,852,934
RAC: 0
New Zealand
Message 1059366 - Posted: 24 Dec 2010, 13:14:31 UTC - in response to Message 1059360.  

+1
ID: 1059366 · Report as offensive
Profile Lint trap

Send message
Joined: 30 May 03
Posts: 871
Credit: 28,092,319
RAC: 0
United States
Message 1059369 - Posted: 24 Dec 2010, 13:36:40 UTC
Last modified: 24 Dec 2010, 13:55:30 UTC

ISTM that db accesses are required to get a total. So, if there was a sum displayed by default all pending wu's would be counted every time someone loaded their account page. Not a good thing.

IF the db was keepig a running total that was updated only when new credit was pending or pending was finally granted, then a dynamic display would be feasible. BUT, if anything happened to wipe out multiple users data, that could be disastrous as the db stresses to recalculate all the totals. And the extra workload during high client access periods, after an outage for instance, would be an additional strain.

Until db accesses become a "no prob-lem-o", maybe it should stay as it is...

Martin
[slight edit]
ID: 1059369 · Report as offensive
Richard Haselgrove Project Donor
Volunteer tester

Send message
Joined: 4 Jul 99
Posts: 14653
Credit: 200,643,578
RAC: 874
United Kingdom
Message 1059379 - Posted: 24 Dec 2010, 14:29:47 UTC - in response to Message 1059369.  

ISTM that db accesses are required to get a total.....

That does seem to be the way it's written. Looking at http://boinc.berkeley.edu/trac/browser/trunk/boinc/html/user/pending.php, the key lines are:

45     $results = BoincResult::enum("userid=$user->id AND (validate_state=0 OR validate_state=4) AND claimed_credit > 0"); 
46     foreach($results as $result) { 
47         echo "<result>\n"; 
48         echo "    <resultid>".$result->id."</resultid>\n"; 
49         echo "    <workunitid>".$result->workunitid."</workunitid>\n"; 
50         echo "    <hostid>".$result->hostid."</hostid>\n"; 
51         echo "    <claimed_credit>".$result->claimed_credit."</claimed_credit>\n"; 
52         echo "    <received_time>".$result->received_time."</received_time>\n"; 
53         echo "</result>\n"; 
54         $sum += $result->claimed_credit; 
55     } 

So yes, not only is each pending record retrieved from the database, but the total is accumulated while the list is stepped through and printed. The server doesn't know the total until the end of the page is reached.

An alternative would be to leave the link on the account page as it is (so no DB access is triggered), but rewrite pending.php so that when the page is first accessed, the first thing the user sees is the total figure, with a "show details" button/link/expand to invoke the current full list.

It should be easy to write an eqivalent of line 45, returning the sum directly using SQL functions - that should be a much 'lighter' query than the enum, and save on the server memory requirement of the $results vector [which might have a bearing on the Wondering when my pending credit page will fail....... question].

Anyone here got good enough PHP skills to write a patch? (I did an evening class in PHP once, but I think some practical experience would be advisable before submission.....)
ID: 1059379 · Report as offensive
Cruncher-American Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor

Send message
Joined: 25 Mar 02
Posts: 1513
Credit: 370,893,186
RAC: 340
United States
Message 1059380 - Posted: 24 Dec 2010, 14:32:17 UTC - in response to Message 1059369.  

ISTM that db accesses are required to get a total. So, if there was a sum displayed by default all pending wu's would be counted every time someone loaded their account page. Not a good thing.

IF the db was keepig a running total that was updated only when new credit was pending or pending was finally granted, then a dynamic display would be feasible. BUT, if anything happened to wipe out multiple users data, that could be disastrous as the db stresses to recalculate all the totals. And the extra workload during high client access periods, after an outage for instance, would be an additional strain.

Until db accesses become a "no prob-lem-o", maybe it should stay as it is...

Martin
[slight edit]


But the total could be got in the same query that gets the other totals as shown. Trust me, I've written lots of SQL queries; the diff between SELECT SUM(a), SUM(b), SUM(c) WHERE... and SELECT SUM(a), SUM(b), SUM(c), SUM (d) WHERE... isn't much.
ID: 1059380 · Report as offensive
Profile Tim Norton
Volunteer tester
Avatar

Send message
Joined: 2 Jun 99
Posts: 835
Credit: 33,540,164
RAC: 0
United Kingdom
Message 1059381 - Posted: 24 Dec 2010, 14:34:42 UTC - in response to Message 1059369.  
Last modified: 24 Dec 2010, 14:35:32 UTC

its simpler than that

just a running total that gets updated at the same time as your RAC is updated - as the numbers are increased or decreased as new results are validated - much lower overhead than pulling back thousands of rows of data

eg. xxx tasks and yyy total potential credit is all most people want - me included

wow beaten to the punch twice! - lol
Tim

ID: 1059381 · Report as offensive
Profile Lint trap

Send message
Joined: 30 May 03
Posts: 871
Credit: 28,092,319
RAC: 0
United States
Message 1059444 - Posted: 24 Dec 2010, 18:23:01 UTC - in response to Message 1059379.  

An alternative would be to leave the link on the account page as it is (so no DB access is triggered), but rewrite pending.php so that when the page is first accessed, the first thing the user sees is the total figure, with a "show details" button/link/expand to invoke the current full list.


Could the total figure be shown on the account page (after the link is clicked)? As jravin pointed out pending details can be seen in the tasks pages.

That may save more bw by not loading a "pending" page/s at all.

Martin
ID: 1059444 · Report as offensive
theCase

Send message
Joined: 25 May 99
Posts: 22
Credit: 2,416,299
RAC: 3
United States
Message 1059454 - Posted: 24 Dec 2010, 19:46:35 UTC

I'd think it's best left alone. Scrolling down to the bottom of the page isn't that hard.

Heck with all the bitching going on about server outage, no W/U's on week-ends, ghosts, etc. I'd think making a change to a functioning screen thats been like this for YEARS is a low priority.
ID: 1059454 · Report as offensive
-BeNt-
Avatar

Send message
Joined: 17 Oct 99
Posts: 1234
Credit: 10,116,112
RAC: 0
United States
Message 1059471 - Posted: 24 Dec 2010, 21:34:52 UTC

Is it really that big of a deal to click a link? While some users the sql query to gather a sum result isn't a huge issue as they don't have that many result to sum up, some users have MANY more than most. Once you start compounding a lot of people per minute / hour/ or whatever it starts overloading the database. Or could. OR may not really now. Personally I would love my result to be displayed underneath there along with how many unit I have pending shown something like 76,000(470) or something like that. But they have their reason and it could be changed later depending on the over all load I suppose. Because after all anyone who is actually viewing those pages a good bit are clicking that link to begin with!
Traveling through space at ~67,000mph!
ID: 1059471 · Report as offensive
Profile bj

Send message
Joined: 11 Oct 00
Posts: 163
Credit: 50,429,507
RAC: 0
United States
Message 1059512 - Posted: 25 Dec 2010, 2:50:14 UTC

Hit the end key on the keyboard.

Been doing that for years.

bj
ID: 1059512 · Report as offensive
kittyman Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor
Volunteer tester
Avatar

Send message
Joined: 9 Jul 00
Posts: 51468
Credit: 1,018,363,574
RAC: 1,004
United States
Message 1059541 - Posted: 25 Dec 2010, 7:47:40 UTC

I agree with the original suggestion that if a pending total could be diplayed without the need for database intensive searches every time a user simply wants to know their pending, it would be a very good thing.
As others have noted, most of the time the only thing of interest is the actual pending total, not the individual WUs that are pending.

I may be oversimplifying things, but I don't see how that could not be kept and updated the same way that one's total credit and RAC is on the user's account page.

I am sure it would involve rewriting code, and is surely not a top priority...
But I see no reason that the pending total could not be kept updated and displayed on the account page just as total credit is right now.
"Freedom is just Chaos, with better lighting." Alan Dean Foster

ID: 1059541 · Report as offensive
Cruncher-American Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor

Send message
Joined: 25 Mar 02
Posts: 1513
Credit: 370,893,186
RAC: 340
United States
Message 1059548 - Posted: 25 Dec 2010, 8:31:09 UTC - in response to Message 1059512.  

Hit the end key on the keyboard.

Been doing that for years.

bj


Yup, but that's not the issue.

The main issues are preventing a) sucking all the rows for pending WUs out of the db and then b) transmitting them to the user, both of which are superfluous almost all the time, and use lots of resources.

And, as noted above, you can get a list of your pending WUs through the Tasks button anyway, so the current Pending button is superfluous.
ID: 1059548 · Report as offensive
kittyman Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor
Volunteer tester
Avatar

Send message
Joined: 9 Jul 00
Posts: 51468
Credit: 1,018,363,574
RAC: 1,004
United States
Message 1059549 - Posted: 25 Dec 2010, 8:33:46 UTC - in response to Message 1059548.  


And, as noted above, you can get a list of your pending WUs through the Tasks button anyway, so the current Pending button is superfluous.

Except viewing one's pending tasks with the tasks button does not give you the total pending credits.
"Freedom is just Chaos, with better lighting." Alan Dean Foster

ID: 1059549 · Report as offensive
Cruncher-American Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor

Send message
Joined: 25 Mar 02
Posts: 1513
Credit: 370,893,186
RAC: 340
United States
Message 1059550 - Posted: 25 Dec 2010, 8:37:35 UTC - in response to Message 1059471.  
Last modified: 25 Dec 2010, 8:39:16 UTC

Is it really that big of a deal to click a link? While some users the sql query to gather a sum result isn't a huge issue as they don't have that many result to sum up, some users have MANY more than most. Once you start compounding a lot of people per minute / hour/ or whatever it starts overloading the database. Or could. OR may not really now. Personally I would love my result to be displayed underneath there along with how many unit I have pending shown something like 76,000(470) or something like that. But they have their reason and it could be changed later depending on the over all load I suppose. Because after all anyone who is actually viewing those pages a good bit are clicking that link to begin with!


But getting those Pending WU rows as a separate query IS a problem for the DB. As I noted above, adding "SUM(Pending WU.credit)" (or whatever) to the query that generates the other totals on the Account page doesn't use a lot of extra resources (since all the WUs are scanned anyway to produce the other totals therein). That was my original point.

Mark:
Except viewing one's pending tasks with the tasks button does not give you the total pending credits.

EXACTLY!
ID: 1059550 · Report as offensive
Profile Uli
Volunteer tester
Avatar

Send message
Joined: 6 Feb 00
Posts: 10923
Credit: 5,996,015
RAC: 1
Germany
Message 1059555 - Posted: 25 Dec 2010, 8:55:28 UTC - in response to Message 1059541.  

I agree with the original suggestion that if a pending total could be diplayed without the need for database intensive searches every time a user simply wants to know their pending, it would be a very good thing.
As others have noted, most of the time the only thing of interest is the actual pending total, not the individual WUs that are pending.


But I see no reason that the pending total could not be kept updated and displayed on the account page just as total credit is right now.


That would be nice Mark and a good idea as well.
Pluto will always be a planet to me.

Seti Ambassador
Not to late to order an Anni Shirt
ID: 1059555 · Report as offensive
-BeNt-
Avatar

Send message
Joined: 17 Oct 99
Posts: 1234
Credit: 10,116,112
RAC: 0
United States
Message 1059558 - Posted: 25 Dec 2010, 9:00:55 UTC - in response to Message 1059550.  


But getting those Pending WU rows as a separate query IS a problem for the DB. As I noted above, adding "SUM(Pending WU.credit)" (or whatever) to the query that generates the other totals on the Account page doesn't use a lot of extra resources (since all the WUs are scanned anyway to produce the other totals therein). That was my original point.


I was agreeing with you?!

Traveling through space at ~67,000mph!
ID: 1059558 · Report as offensive
Cruncher-American Crowdfunding Project Donor*Special Project $75 donorSpecial Project $250 donor

Send message
Joined: 25 Mar 02
Posts: 1513
Credit: 370,893,186
RAC: 340
United States
Message 1059572 - Posted: 25 Dec 2010, 9:28:05 UTC - in response to Message 1059558.  
Last modified: 25 Dec 2010, 9:30:02 UTC


But getting those Pending WU rows as a separate query IS a problem for the DB. As I noted above, adding "SUM(Pending WU.credit)" (or whatever) to the query that generates the other totals on the Account page doesn't use a lot of extra resources (since all the WUs are scanned anyway to produce the other totals therein). That was my original point.


I was agreeing with you?!


My bad! It's too late! And on Xmas, too!

Merry Christmas to all, and to all, a Good Night!
ID: 1059572 · Report as offensive
Profile Helli_retiered
Volunteer tester
Avatar

Send message
Joined: 15 Dec 99
Posts: 707
Credit: 108,785,585
RAC: 0
Germany
Message 1059589 - Posted: 25 Dec 2010, 13:05:12 UTC - in response to Message 1059379.  



...

An alternative would be to leave the link on the account page as it is (so no DB access is triggered), but rewrite pending.php so that when the page is first accessed, the first thing the user sees is the total figure, with a "show details" button/link/expand to invoke the current full list.
...


That would be enough for me. I don't access the Pending Credits Page that much...

Helli
A loooong time ago: First Credits after SETI@home Restart
ID: 1059589 · Report as offensive
W-K 666 Project Donor
Volunteer tester

Send message
Joined: 18 May 99
Posts: 19083
Credit: 40,757,560
RAC: 67
United Kingdom
Message 1059594 - Posted: 25 Dec 2010, 13:32:34 UTC
Last modified: 25 Dec 2010, 13:33:05 UTC

I think the suggestion is desirable but probably impractical.
It would have to be done for every owners account and be refreshed;
a) every time a task is reported and goes into the pendings tray and
b) for every task reported by a wingman and then validated and departs the pendings tray.

This would almost certainly be a large server load, for one entry on the accounts page that is only looked at by at most few thousand owners per day.
ID: 1059594 · Report as offensive
1 · 2 · Next

Message boards : Number crunching : Lobbying Again for Change to Account Page


 
©2024 University of California
 
SETI@home and Astropulse are funded by grants from the National Science Foundation, NASA, and donations from SETI@home volunteers. AstroPulse is funded in part by the NSF through grant AST-0307956.