diff --git a/doc/account.html b/doc/account.php similarity index 89% rename from doc/account.html rename to doc/account.php index e165c84bfd..c507913ec1 100644 --- a/doc/account.html +++ b/doc/account.php @@ -1,6 +1,7 @@ -Joining a project - -

Joining a project

+ You can join a BOINC project as follows: @@ -9,7 +10,7 @@ You can join a BOINC project as follows: This involves filling out a form with @@ -47,3 +48,6 @@ from an existing host to the new host. The BOINC client resides in a BOINC home directory. If hosts share a network file system, each host must have its own BOINC home directory. +"; +page_tail(); +?> diff --git a/doc/backend_functions.php b/doc/backend_functions.php index 5972dc2b95..3f08cf8f45 100644 --- a/doc/backend_functions.php +++ b/doc/backend_functions.php @@ -24,19 +24,20 @@ This can result from tampering or hardware failures. This problem can be addressed by redundant computing In this approach, each workunit is processed at least twice. -The project back end waits until a minimum number of results have been returned,then compares the results and decides which are considered correct. +The project back end waits until a minimum number of results have been returned, +then compares the results and decides which are considered correct. The notion of equality of results, and the policy for deciding which are correct, are project-specific.

  • Grant credit. - Some users will attempt to get undeserved credit by falsifying their CPU - metrics or CPU times. Each project and application can have its own - credit-granting algorithm, for example granting the minimum or the mean of - the median of all claimed credits (during validation time). The granted - credit is assigned to all correct results. This ensures that as long as a - reasonable majority of participants don't falsify credit, almost all credit - accounting will be correct. +Some users will attempt to get undeserved credit by falsifying their CPU +metrics or CPU times. Each project and application can have its own +credit-granting algorithm, for example granting the minimum or the mean of +the median of all claimed credits (during validation time). The granted +credit is assigned to all correct results. This ensures that as long as a +reasonable majority of participants don't falsify credit, almost all credit +accounting will be correct.

  • Assimilate results.

    diff --git a/doc/backend_state.php b/doc/backend_state.php index 9878e1851a..cfe702544b 100644 --- a/doc/backend_state.php +++ b/doc/backend_state.php @@ -1,65 +1,97 @@ -The processing of workunits and results involves several independent activities. -To keep track of these activities, -workunit and result database records have several parameters and state fields, -and their processing can be expressed in terms of state machines. +Workunit and result database records have several state fields, +and their processing can be described in terms of state transitions. -


    -

    Workunit.delay_bound

    -An upper bound for the interval between when a scheduler -sends an instance of this WU to a host -when the host sends the completion message. -It should be several times the execution time on an average host. -If it's exceeded, the server 'gives up' on the result -and may delete its input files. -If the result is returned later, -it will still be validated and credited. +

    +Several workunits parameters are described +here. -

    Workunit.canonical_resultid

    -The ID of the canonical result for this workunit, or zero. +Other state fields include +"; +list_start(); +list_item( + "canonical_resultid", + "The ID of the canonical result for this workunit, or zero." +); -

    Workunit.timeout_check_time

    -The next time to check for timeouts on this WU -(e.g. to give up on results and create new ones). -
    -
    -
    - +list_item("transition_time", + "The next time to check for state transitions for this WU. + + " +); +list_item("file_delete_state", + "Indicates whether input files should be deleted. + + " +); -

    Workunit.file_delete_state

    -Indicates whether input files should be deleted. -
    -
    -
    +list_item("assimilate_state", + "Indicates whether the workunit should be assimilated. + + " +); -

    Workunit.assimilate_state

    -Indicates whether the workunit should be assimilated. -
    -
    -
    +list_item("need_validate", + "Indicates that the workunit has a result that needs validation. + + " +); -

    Workunit.need_validate

    -Indicates that the workunit has a result that needs validation. -
    -
    -
    - -

    Workunit.error_mask

    -A bit mask for error conditions. -
    -
    -
    +list_item("error_mask", + "A bit mask for error conditions. + + " +); +list_end(); +echo " Workunit invariants: +"; -
    +list_start(); +list_item("report_deadline", + "Give up on result (and possibly delete input files) + if don't get reply by this time. + + " +); +list_item("server_state", + "Values: UNSENT, IN_PROGRESS, OVER + + " +); +list_item("outcome", + "Values: SUCCESS, COULDNT_SEND, CLIENT_ERROR, NO_REPLY, DIDNT_NEED. +
    Defined iff result.server_state=OVER + + " +); +list_item("client_state", + "Records the client state (upload, process, or download) + where an error occurred. + Defined if outcome is CLIENT_ERROR. + " +); -

    Result.report_deadline

    -give up on result (and possibly delete input files) -if don't get reply by this time. -

    -Assignment: when send result; now + WU.delay_bound +list_item("file_delete_state", + " +

    +"; +page_tail(); +?> diff --git a/doc/tools_security.html b/doc/tools_security.html deleted file mode 100644 index 3ab25ffa5f..0000000000 --- a/doc/tools_security.html +++ /dev/null @@ -1,23 +0,0 @@ -Security tools - -

    Security tools

    -

    -The program lib/crypt_prog can be used for several purposes: -
    -

    -
    crypt_prog -genkey n private_keyfile public_keyfile -
    -Create a key pair with n bits (always use 1024). -Write the keys in encoded ASCII form to the indicated files. -
    crypt_prog -sign file private_keyfile -
    -Create a digital signature for the given file. Write it in encoded -ASCII to stdout. -
    crypt_prog -verify file signature_file public_keyfile -
    -Verify a signature for the given file. -
    crypt_prog -test_crypt private_keyfile public_keyfile -
    -Perform an internal test, checking that encryption followed by -decryption works. -
    \ No newline at end of file diff --git a/doc/version.html b/doc/version.html deleted file mode 100644 index 118c074362..0000000000 --- a/doc/version.html +++ /dev/null @@ -1 +0,0 @@ -Delete this file \ No newline at end of file diff --git a/doc/work.php b/doc/work.php index f530233593..6987ca46fd 100644 --- a/doc/work.php +++ b/doc/work.php @@ -125,8 +125,8 @@ list_end(); echo "

    -The create_work utility program provides a -simplified interface for creating workunits. +BOINC provides a utility program and C function +for creating workunits. "; page_tail(); diff --git a/doc/work_buffer.php b/doc/work_buffer.php new file mode 100644 index 0000000000..c382d9e470 --- /dev/null +++ b/doc/work_buffer.php @@ -0,0 +1,24 @@ + +Each BOINC client +maintains an estimate of the amount of work remaining +(i.e. the time until one of its processors will be idle). +Each host also has two preferences: +the minimum work and the +maximum work +(these are part of your 'general preferences', discussed elsewhere). +

    +Normally the work remaining is between these two limits. +When the work remaining reaches minimum level, +the client contacts one or more scheduling servers, +and attempts to get enough work to exceed the maximum level. +

    +This scheme allows hosts that are sporadically connected +(because they're portable or have modem-based connections) +to avoid becoming idle due to lack of work. +"; +page_tail(); +?> diff --git a/doc/wu_assimilate.fig b/doc/wu_assimilate.fig deleted file mode 100644 index b03a2b21e0..0000000000 --- a/doc/wu_assimilate.fig +++ /dev/null @@ -1,112 +0,0 @@ -#FIG 3.2 -Landscape -Center -Inches -Letter -100.00 -Single --2 -1200 2 -0 32 #c7b696 -0 33 #effbff -0 34 #dfcba6 -0 35 #414141 -0 36 #868286 -0 37 #c7c3c7 -0 38 #e7e3e7 -0 39 #8e8e8e -0 40 #aeaaae -0 41 #515551 -0 42 #414141 -0 43 #868286 -0 44 #c7c3c7 -0 45 #868286 -0 46 #c7c3c7 -0 47 #e7e3e7 -0 48 #8e8e8e -0 49 #8e8e8e -0 50 #414141 -0 51 #868286 -0 52 #c7c3c7 -0 53 #e7e3e7 -0 54 #414141 -0 55 #868286 -0 56 #c7c3c7 -0 57 #e7e3e7 -0 58 #868286 -0 59 #c7c3c7 -0 60 #e7e3e7 -0 61 #c7b696 -0 62 #effbff -0 63 #dfcba6 -0 64 #c7b696 -0 65 #effbff -0 66 #dfcba6 -0 67 #aeaaae -0 68 #515551 -0 69 #8e8e8e -0 70 #414141 -0 71 #868286 -0 72 #c7c3c7 -0 73 #e7e3e7 -0 74 #414141 -0 75 #868286 -0 76 #c7c3c7 -0 77 #e7e3e7 -0 78 #868286 -0 79 #c7c3c7 -0 80 #e7e3e7 -0 81 #414141 -0 82 #868286 -0 83 #c7c3c7 -0 84 #414141 -0 85 #c7c3c7 -0 86 #e7e3e7 -0 87 #414141 -0 88 #868286 -0 89 #c7c3c7 -0 90 #8e8e8e -0 91 #414141 -0 92 #868286 -0 93 #c7c3c7 -0 94 #e7e3e7 -0 95 #414141 -0 96 #868286 -0 97 #c7c3c7 -0 98 #e7e3e7 -0 99 #bebebe -0 100 #515151 -0 101 #000049 -0 102 #797979 -0 103 #303430 -0 104 #414541 -0 105 #414141 -0 106 #868286 -0 107 #c7c3c7 -0 108 #e7e3e7 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 1725 4950 2475 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 2925 4950 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 2475 5325 2475 5325 2925 4575 2925 4575 2475 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 3750 5400 3750 5400 4200 4500 4200 4500 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 5175 5400 5175 5400 5625 4575 5625 4575 5175 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 3750 5400 3750 5400 4200 4500 4200 4500 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 5175 5400 5175 5400 5625 4575 5625 4575 5175 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 4200 4950 5175 -4 0 0 50 0 16 12 0.0000 4 135 435 5100 2100 initial\001 -4 0 0 50 0 16 12 0.0000 4 135 330 4800 2775 INIT\001 -4 0 0 50 0 16 12 0.0000 4 135 645 4650 4050 READY\001 -4 0 0 50 0 16 12 0.0000 4 135 540 4725 5475 DONE\001 -4 0 0 50 0 16 12 0.0000 4 135 1395 5100 4650 assimilator: done\001 -4 0 0 50 0 16 12 0.0000 4 135 2625 5100 3525 validate: found canonical result\001 -4 0 0 50 0 16 12 0.0000 4 165 2400 5100 3225 timeout_check: WU has error\001 diff --git a/doc/wu_assimilate.png b/doc/wu_assimilate.png deleted file mode 100644 index e53ec98f99..0000000000 Binary files a/doc/wu_assimilate.png and /dev/null differ diff --git a/doc/wu_error_mask.fig b/doc/wu_error_mask.fig deleted file mode 100644 index 88bed2296a..0000000000 --- a/doc/wu_error_mask.fig +++ /dev/null @@ -1,113 +0,0 @@ -#FIG 3.2 -Landscape -Center -Inches -Letter -100.00 -Single --2 -1200 2 -0 32 #c7b696 -0 33 #effbff -0 34 #dfcba6 -0 35 #414141 -0 36 #868286 -0 37 #c7c3c7 -0 38 #e7e3e7 -0 39 #8e8e8e -0 40 #aeaaae -0 41 #515551 -0 42 #414141 -0 43 #868286 -0 44 #c7c3c7 -0 45 #868286 -0 46 #c7c3c7 -0 47 #e7e3e7 -0 48 #8e8e8e -0 49 #8e8e8e -0 50 #414141 -0 51 #868286 -0 52 #c7c3c7 -0 53 #e7e3e7 -0 54 #414141 -0 55 #868286 -0 56 #c7c3c7 -0 57 #e7e3e7 -0 58 #868286 -0 59 #c7c3c7 -0 60 #e7e3e7 -0 61 #c7b696 -0 62 #effbff -0 63 #dfcba6 -0 64 #c7b696 -0 65 #effbff -0 66 #dfcba6 -0 67 #aeaaae -0 68 #515551 -0 69 #8e8e8e -0 70 #414141 -0 71 #868286 -0 72 #c7c3c7 -0 73 #e7e3e7 -0 74 #414141 -0 75 #868286 -0 76 #c7c3c7 -0 77 #e7e3e7 -0 78 #868286 -0 79 #c7c3c7 -0 80 #e7e3e7 -0 81 #414141 -0 82 #868286 -0 83 #c7c3c7 -0 84 #414141 -0 85 #c7c3c7 -0 86 #e7e3e7 -0 87 #414141 -0 88 #868286 -0 89 #c7c3c7 -0 90 #8e8e8e -0 91 #414141 -0 92 #868286 -0 93 #c7c3c7 -0 94 #e7e3e7 -0 95 #414141 -0 96 #868286 -0 97 #c7c3c7 -0 98 #e7e3e7 -0 99 #bebebe -0 100 #515151 -0 101 #000049 -0 102 #797979 -0 103 #303430 -0 104 #414541 -0 105 #414141 -0 106 #868286 -0 107 #c7c3c7 -0 108 #e7e3e7 -6 4575 5175 6375 5625 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 5175 6375 5175 6375 5625 4575 5625 4575 5175 -4 0 0 50 0 16 12 0.0000 4 165 1500 4725 5475 COULDNT_SEND\001 --6 -6 4500 3750 7500 4200 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 3750 7500 3750 7500 4200 4500 4200 4500 3750 -4 0 0 50 0 16 12 0.0000 4 165 2730 4650 4050 TOO_MANY_ERROR_RESULTS\001 --6 -6 4650 2475 6975 2925 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4650 2475 6975 2475 6975 2925 4650 2925 4650 2475 -4 0 0 50 0 16 12 0.0000 4 165 1995 4800 2775 TOO_MANY_RESULTS\001 --6 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 2100 4950 2475 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 3300 4950 3750 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 4650 4950 5175 -4 0 0 50 0 16 12 0.0000 4 180 3120 5100 3525 timeout_check: too many error results\001 -4 0 0 50 0 16 12 0.0000 4 180 2670 5100 2325 timeout_check: too many results\001 -4 0 0 50 0 16 12 0.0000 4 165 4980 5100 4950 timeout_check: some result has outcome=COULDNT_SEND\001 diff --git a/doc/wu_error_mask.png b/doc/wu_error_mask.png deleted file mode 100644 index 9a59f1f7ef..0000000000 Binary files a/doc/wu_error_mask.png and /dev/null differ diff --git a/doc/wu_file_delete.fig b/doc/wu_file_delete.fig deleted file mode 100644 index 88883e9521..0000000000 --- a/doc/wu_file_delete.fig +++ /dev/null @@ -1,112 +0,0 @@ -#FIG 3.2 -Landscape -Center -Inches -Letter -100.00 -Single --2 -1200 2 -0 32 #c7b696 -0 33 #effbff -0 34 #dfcba6 -0 35 #414141 -0 36 #868286 -0 37 #c7c3c7 -0 38 #e7e3e7 -0 39 #8e8e8e -0 40 #aeaaae -0 41 #515551 -0 42 #414141 -0 43 #868286 -0 44 #c7c3c7 -0 45 #868286 -0 46 #c7c3c7 -0 47 #e7e3e7 -0 48 #8e8e8e -0 49 #8e8e8e -0 50 #414141 -0 51 #868286 -0 52 #c7c3c7 -0 53 #e7e3e7 -0 54 #414141 -0 55 #868286 -0 56 #c7c3c7 -0 57 #e7e3e7 -0 58 #868286 -0 59 #c7c3c7 -0 60 #e7e3e7 -0 61 #c7b696 -0 62 #effbff -0 63 #dfcba6 -0 64 #c7b696 -0 65 #effbff -0 66 #dfcba6 -0 67 #aeaaae -0 68 #515551 -0 69 #8e8e8e -0 70 #414141 -0 71 #868286 -0 72 #c7c3c7 -0 73 #e7e3e7 -0 74 #414141 -0 75 #868286 -0 76 #c7c3c7 -0 77 #e7e3e7 -0 78 #868286 -0 79 #c7c3c7 -0 80 #e7e3e7 -0 81 #414141 -0 82 #868286 -0 83 #c7c3c7 -0 84 #414141 -0 85 #c7c3c7 -0 86 #e7e3e7 -0 87 #414141 -0 88 #868286 -0 89 #c7c3c7 -0 90 #8e8e8e -0 91 #414141 -0 92 #868286 -0 93 #c7c3c7 -0 94 #e7e3e7 -0 95 #414141 -0 96 #868286 -0 97 #c7c3c7 -0 98 #e7e3e7 -0 99 #bebebe -0 100 #515151 -0 101 #000049 -0 102 #797979 -0 103 #303430 -0 104 #414541 -0 105 #414141 -0 106 #868286 -0 107 #c7c3c7 -0 108 #e7e3e7 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 1725 4950 2475 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 2925 4950 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 2475 5325 2475 5325 2925 4575 2925 4575 2475 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 3750 5400 3750 5400 4200 4500 4200 4500 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 5175 5400 5175 5400 5625 4575 5625 4575 5175 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 3750 5400 3750 5400 4200 4500 4200 4500 3750 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 5175 5400 5175 5400 5625 4575 5625 4575 5175 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 4200 4950 5175 -4 0 0 50 0 16 12 0.0000 4 135 435 5100 2100 initial\001 -4 0 0 50 0 16 12 0.0000 4 135 330 4800 2775 INIT\001 -4 0 0 50 0 16 12 0.0000 4 135 645 4650 4050 READY\001 -4 0 0 50 0 16 12 0.0000 4 135 540 4725 5475 DONE\001 -4 0 0 50 0 16 12 0.0000 4 165 6960 5100 3150 timeout_check: all results have server_state=OVER and wu.assimilate_state=DONE\001 -4 0 0 50 0 16 12 0.0000 4 180 6690 5100 3375 assimilate: all results have server_state=OVER (and wu.assimilate_state=DONE)\001 -4 0 0 50 0 16 12 0.0000 4 165 2550 2250 4725 file_deleter: tried to delete files\001 diff --git a/doc/wu_file_delete.png b/doc/wu_file_delete.png deleted file mode 100644 index 7a977eb1f6..0000000000 Binary files a/doc/wu_file_delete.png and /dev/null differ diff --git a/doc/wu_need_validate.fig b/doc/wu_need_validate.fig deleted file mode 100644 index d97d749d3f..0000000000 --- a/doc/wu_need_validate.fig +++ /dev/null @@ -1,106 +0,0 @@ -#FIG 3.2 -Landscape -Center -Inches -Letter -100.00 -Single --2 -1200 2 -0 32 #c7b696 -0 33 #effbff -0 34 #dfcba6 -0 35 #414141 -0 36 #868286 -0 37 #c7c3c7 -0 38 #e7e3e7 -0 39 #8e8e8e -0 40 #aeaaae -0 41 #515551 -0 42 #414141 -0 43 #868286 -0 44 #c7c3c7 -0 45 #868286 -0 46 #c7c3c7 -0 47 #e7e3e7 -0 48 #8e8e8e -0 49 #8e8e8e -0 50 #414141 -0 51 #868286 -0 52 #c7c3c7 -0 53 #e7e3e7 -0 54 #414141 -0 55 #868286 -0 56 #c7c3c7 -0 57 #e7e3e7 -0 58 #868286 -0 59 #c7c3c7 -0 60 #e7e3e7 -0 61 #c7b696 -0 62 #effbff -0 63 #dfcba6 -0 64 #c7b696 -0 65 #effbff -0 66 #dfcba6 -0 67 #aeaaae -0 68 #515551 -0 69 #8e8e8e -0 70 #414141 -0 71 #868286 -0 72 #c7c3c7 -0 73 #e7e3e7 -0 74 #414141 -0 75 #868286 -0 76 #c7c3c7 -0 77 #e7e3e7 -0 78 #868286 -0 79 #c7c3c7 -0 80 #e7e3e7 -0 81 #414141 -0 82 #868286 -0 83 #c7c3c7 -0 84 #414141 -0 85 #c7c3c7 -0 86 #e7e3e7 -0 87 #414141 -0 88 #868286 -0 89 #c7c3c7 -0 90 #8e8e8e -0 91 #414141 -0 92 #868286 -0 93 #c7c3c7 -0 94 #e7e3e7 -0 95 #414141 -0 96 #868286 -0 97 #c7c3c7 -0 98 #e7e3e7 -0 99 #bebebe -0 100 #515151 -0 101 #000049 -0 102 #797979 -0 103 #303430 -0 104 #414541 -0 105 #414141 -0 106 #868286 -0 107 #c7c3c7 -0 108 #e7e3e7 -6 4500 4050 5400 4500 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4500 4050 5400 4050 5400 4500 4500 4500 4500 4050 -4 0 0 50 0 16 12 0.0000 4 135 465 4650 4350 TRUE\001 --6 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 1725 4950 2475 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 2475 5325 2475 5325 2925 4575 2925 4575 2475 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4800 2925 4800 4050 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 0 1 2 - 0 0 1.00 60.00 120.00 - 5175 2925 5175 4050 -4 0 0 50 0 16 12 0.0000 4 135 435 5100 2100 initial\001 -4 0 0 50 0 16 12 0.0000 4 135 600 4650 2775 FALSE\001 -4 0 0 50 0 16 12 0.0000 4 180 3660 975 3525 scheduler: got reply with client_state DONE\001 -4 0 0 50 0 16 12 0.0000 4 180 2010 5400 3525 validate: done checking\001 diff --git a/doc/wu_need_validate.png b/doc/wu_need_validate.png deleted file mode 100644 index b8abb3972d..0000000000 Binary files a/doc/wu_need_validate.png and /dev/null differ diff --git a/doc/wu_timeout.fig b/doc/wu_timeout.fig deleted file mode 100644 index 2ce69ee719..0000000000 --- a/doc/wu_timeout.fig +++ /dev/null @@ -1,108 +0,0 @@ -#FIG 3.2 -Landscape -Center -Inches -Letter -100.00 -Single --2 -1200 2 -0 32 #c7b696 -0 33 #effbff -0 34 #dfcba6 -0 35 #414141 -0 36 #868286 -0 37 #c7c3c7 -0 38 #e7e3e7 -0 39 #8e8e8e -0 40 #aeaaae -0 41 #515551 -0 42 #414141 -0 43 #868286 -0 44 #c7c3c7 -0 45 #868286 -0 46 #c7c3c7 -0 47 #e7e3e7 -0 48 #8e8e8e -0 49 #8e8e8e -0 50 #414141 -0 51 #868286 -0 52 #c7c3c7 -0 53 #e7e3e7 -0 54 #414141 -0 55 #868286 -0 56 #c7c3c7 -0 57 #e7e3e7 -0 58 #868286 -0 59 #c7c3c7 -0 60 #e7e3e7 -0 61 #c7b696 -0 62 #effbff -0 63 #dfcba6 -0 64 #c7b696 -0 65 #effbff -0 66 #dfcba6 -0 67 #aeaaae -0 68 #515551 -0 69 #8e8e8e -0 70 #414141 -0 71 #868286 -0 72 #c7c3c7 -0 73 #e7e3e7 -0 74 #414141 -0 75 #868286 -0 76 #c7c3c7 -0 77 #e7e3e7 -0 78 #868286 -0 79 #c7c3c7 -0 80 #e7e3e7 -0 81 #414141 -0 82 #868286 -0 83 #c7c3c7 -0 84 #414141 -0 85 #c7c3c7 -0 86 #e7e3e7 -0 87 #414141 -0 88 #868286 -0 89 #c7c3c7 -0 90 #8e8e8e -0 91 #414141 -0 92 #868286 -0 93 #c7c3c7 -0 94 #e7e3e7 -0 95 #414141 -0 96 #868286 -0 97 #c7c3c7 -0 98 #e7e3e7 -0 99 #bebebe -0 100 #515151 -0 101 #000049 -0 102 #797979 -0 103 #303430 -0 104 #414541 -0 105 #414141 -0 106 #868286 -0 107 #c7c3c7 -0 108 #e7e3e7 -6 4275 2475 5625 2925 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4275 2475 5625 2475 5625 2925 4275 2925 4275 2475 -4 0 0 50 0 16 12 0.0000 4 135 945 4425 2775 NONZERO\001 --6 -6 4575 4050 5325 4500 -2 2 0 1 0 7 50 0 -1 0.000 0 0 -1 0 0 5 - 4575 4050 5325 4050 5325 4500 4575 4500 4575 4050 -4 0 0 50 0 16 12 0.0000 4 135 525 4650 4350 ZERO\001 --6 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4950 1725 4950 2475 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 2 - 0 0 1.00 60.00 120.00 - 4800 2925 4800 4050 -2 1 0 1 0 7 50 0 -1 0.000 0 0 -1 1 0 4 - 0 0 1.00 60.00 120.00 - 5625 2550 6225 2550 6225 2850 5625 2850 -4 0 0 50 0 16 12 0.0000 4 135 435 5100 2100 initial\001 -4 0 0 50 0 16 12 0.0000 4 165 2100 6375 2775 timeout_check: otherwise\001 -4 0 0 50 0 16 12 0.0000 4 165 5250 5025 3525 timeout_check: all results are OVER and validate_state=DONE\001 diff --git a/doc/wu_timeout.png b/doc/wu_timeout.png deleted file mode 100644 index 8b1c38caf8..0000000000 Binary files a/doc/wu_timeout.png and /dev/null differ diff --git a/sched/validate.C b/sched/validate.C index 989525bd48..266d37cd7b 100644 --- a/sched/validate.C +++ b/sched/validate.C @@ -116,13 +116,9 @@ void handle_wu(DB_WORKUNIT& wu) { } // scan this WU's results, and check the unchecked ones + // TODO: do we have an index on these fields? + // maybe better just to enum on workunitid // - // sprintf(buf, "where workunitid=%d", wu.id); - // while (!result.enumerate(buf)) { - // if (result.validate_state == VALIDATE_STATE_INIT - // && result.server_state == RESULT_SERVER_STATE_OVER - // && result.outcome == RESULT_OUTCOME_SUCCESS - // ) { sprintf(buf, "where workunitid=%d and validate_state=%d and server_state=%d and outcome=%d", wu.id, VALIDATE_STATE_INIT, RESULT_SERVER_STATE_OVER, RESULT_OUTCOME_SUCCESS ); @@ -192,6 +188,8 @@ void handle_wu(DB_WORKUNIT& wu) { ++log_messages; // sprintf(buf, "where workunitid=%d", wu.id); + // TODO: do we have an index on these fields? + // maybe better to enum on workunitid // while (!result.enumerate(buf)) { // if (result.server_state == RESULT_SERVER_STATE_OVER // && result.outcome == RESULT_OUTCOME_SUCCESS diff --git a/sched/validate_util.C b/sched/validate_util.C index 78565b0600..c9e420e3d8 100644 --- a/sched/validate_util.C +++ b/sched/validate_util.C @@ -46,8 +46,7 @@ int get_output_file_path(RESULT const& result, string& path) { // - if N==2, give min credit // - if N>2, toss out min and max, give average of rest // -double median_mean_credit(vector const& results) -{ +double median_mean_credit(vector const& results) { typedef vector::const_iterator it; it it_low = results.end(), it_high; @@ -55,12 +54,9 @@ double median_mean_credit(vector const& results) size_t n_valid = 0; - for (it i = results.begin(); i != results.end(); ++i) - { + for (it i = results.begin(); i != results.end(); ++i) { if (i->validate_state != VALIDATE_STATE_VALID) continue; - ++n_valid; - if (it_low == results.end()) { it_low = it_high = i; credit_low = credit_high = i->claimed_credit; @@ -88,8 +84,7 @@ double median_mean_credit(vector const& results) } else { double sum = 0; - for (it i = results.begin(); i != results.end(); ++i) - { + for (it i = results.begin(); i != results.end(); ++i) { if (i == it_low) continue; if (i == it_high) continue; if (i->validate_state != VALIDATE_STATE_VALID) continue; @@ -116,11 +111,12 @@ double median_mean_credit(vector const& results) // // see validate_test.C example usage. // -int generic_check_set_majority(vector& results, int& canonicalid, double& credit, - init_result_f init_result_f, - check_pair_with_data_f check_pair_with_data_f, - cleanup_result_f cleanup_result_f) -{ +int generic_check_set_majority( + vector& results, int& canonicalid, double& credit, + init_result_f init_result_f, + check_pair_with_data_f check_pair_with_data_f, + cleanup_result_f cleanup_result_f +) { assert (!results.empty()); vector data; @@ -128,8 +124,7 @@ int generic_check_set_majority(vector& results, int& canonicalid, double data.resize(n); // 1. INITIALIZE DATA - for (i = 0; i != n; ++i) - { + for (i = 0; i != n; ++i) { if (init_result_f(results[i], data[i])) { log_messages.printf( SchedMessages::CRITICAL, @@ -140,8 +135,7 @@ int generic_check_set_majority(vector& results, int& canonicalid, double } // 2. COMPARE - for (i = 0; i != n; ++i) - { + for (i = 0; i != n; ++i) { vector matches; matches.resize(n); neq = 0; @@ -179,11 +173,12 @@ cleanup: return 0; } -int generic_check_pair(RESULT const& r1, RESULT const& r2, bool& match, - init_result_f init_result_f, - check_pair_with_data_f check_pair_with_data_f, - cleanup_result_f cleanup_result_f) -{ +int generic_check_pair( + RESULT const& r1, RESULT const& r2, bool& match, + init_result_f init_result_f, + check_pair_with_data_f check_pair_with_data_f, + cleanup_result_f cleanup_result_f +) { void* data1; void* data2; int retval; diff --git a/sched/validate_util.h b/sched/validate_util.h index 3a0c6204c8..50870594a4 100644 --- a/sched/validate_util.h +++ b/sched/validate_util.h @@ -31,13 +31,17 @@ typedef int (*check_pair_with_data_f)(RESULT const&, void*, RESULT const&, void* typedef int (*cleanup_result_f)(RESULT const&, void*); int get_output_file_path(RESULT const& result, string& path); double median_mean_credit(vector const& results); -int generic_check_set_majority(vector& results, int& canonicalid, double& credit, - init_result_f init_result_f, - check_pair_with_data_f check_pair_with_data_f, - cleanup_result_f cleanup_result_f); -int generic_check_pair(RESULT const& r1, RESULT const& r2, bool& match, - init_result_f init_result_f, - check_pair_with_data_f check_pair_with_data_f, - cleanup_result_f cleanup_result_f); +int generic_check_set_majority( + vector& results, int& canonicalid, double& credit, + init_result_f init_result_f, + check_pair_with_data_f check_pair_with_data_f, + cleanup_result_f cleanup_result_f +); +int generic_check_pair( + RESULT const& r1, RESULT const& r2, bool& match, + init_result_f init_result_f, + check_pair_with_data_f check_pair_with_data_f, + cleanup_result_f cleanup_result_f +); #endif diff --git a/todo b/todo index 99bcca23cb..80285a3ccf 100755 --- a/todo +++ b/todo @@ -1,5 +1,7 @@ DON'T ADD ANYTHING TO HERE. USE THE TASKBASE INSTEAD. +encrypt IDs in URLs (e.g. host) + Use GlobalMemoryStatusEx when possible on Windows Take p_ncpus into account when assigned work to a host File upload handler should check for disk full, diff --git a/tools/create_work.C b/tools/create_work.C index 8939d34be6..053a867795 100644 --- a/tools/create_work.C +++ b/tools/create_work.C @@ -170,7 +170,6 @@ int main(int argc, char** argv) { } wu.appid = app.id; - wu.transition_time = MAXINT; retval = read_key_file(keyfile, key); if (retval) {