diff --git a/TODO b/TODO index a79a60b4ec..82af3a71a6 100644 --- a/TODO +++ b/TODO @@ -151,6 +151,9 @@ LOW-PRIORITY and output directly in result (blob). For projects with small data. +- add a handler for SIGTERM that calls exit_tasks and makes sure state files + are written. + -------------------------- DONE (may need test) Please document these! diff --git a/api/api.h b/api/api.h index d6e8b78bd0..71f8320ab3 100644 --- a/api/api.h +++ b/api/api.h @@ -53,10 +53,13 @@ public: // - call boinc_init(APP_IN&) at startup // - call time_to_checkpoint() often. // This is cheap - it returns true if time to checkpoint. -// - checkpoint as often as requested by core +// - checkpoint if time_to_checkpoint() returns true // - call checkpoint_completed() when checkpoint is complete +// The only member of APP_OUT that needs to be filled in is percent_done // - boinc_poll(): // Call this as often as requested by core +// - call app_completed() when the application is completed +// The only member of APP_OUT that needs to be filled in is percent_done struct APP_IN_GRAPHICS { int xsize; @@ -77,8 +80,8 @@ struct APP_IN { }; struct APP_OUT { - double percent_done; - double cpu_time_at_checkpoint; + double percent_done; //percent of work unit completed + double cpu_time_at_checkpoint; //cpu time of current process bool checkpointed; // true iff checkpointed since last call }; @@ -98,13 +101,13 @@ int boinc_resolve_link(char *file_name, char *resolved_name); #define BOINC_INIT_FILE "boinc_init.xml" //the following are provided for implementation of the checkpoint system -int checkpoint_completed(APP_OUT& ao); -int app_completed(APP_OUT& ao); +int checkpoint_completed(APP_OUT& ao); //call this when checkpoint is completed +int app_completed(APP_OUT& ao); //call this when app is completed extern bool _checkpoint; #define time_to_checkpoint() _checkpoint int set_timer(double period); //period is seconds spent in process -void on_timer(int not_used); +void on_timer(int not_used); //sets _checkpoint to true double get_cpu_time(); //return cpu time for this process #endif diff --git a/checkin_notes b/checkin_notes index 43e8554ad1..1a96e5facf 100755 --- a/checkin_notes +++ b/checkin_notes @@ -1151,6 +1151,9 @@ David A July 15, 2002 Michael Gary July 15, 2002 - Fixed compile bug - Updated documentation + - Fixed test script bug + - Added comments to some .h files + - Fixed timing bug doc/ api.html client_debug.html @@ -1162,3 +1165,13 @@ Michael Gary July 15, 2002 test.html tools/ Makefile.in + test/ + test_uc.php + test_rsc.php + init.inc + client/ + client_types.h + hostinfo.h + api/ + api.C + api.h diff --git a/client/client_types.h b/client/client_types.h index 000e131bd8..193ae54353 100644 --- a/client/client_types.h +++ b/client/client_types.h @@ -46,7 +46,8 @@ public: // the following items come from prefs.xml // They are a function only of the user and the project // - char master_url[256]; + char master_url[256]; // url of site that contains scheduler tags + // for this project char authenticator[256]; // user's authenticator on this project char* project_specific_prefs; double resource_share; // project's resource share @@ -179,7 +180,7 @@ struct RESULT { bool is_active; // an app is currently running for this bool is_compute_done; // computation finished bool is_server_ack; // ack received from scheduling server - double cpu_time; + double cpu_time; // cpu time spent completing result int exit_status; char stderr_out[STDERR_MAX_LEN]; APP* app; diff --git a/client/hostinfo.h b/client/hostinfo.h index 5873760fb5..363c1f2531 100644 --- a/client/hostinfo.h +++ b/client/hostinfo.h @@ -30,6 +30,7 @@ struct HOST_INFO { char serialnum[256]; char ip_addr[256]; + //exponentially weighted fractions double on_frac; double conn_frac; double active_frac; diff --git a/test/master.html b/test/master.html index 60044e2e7a..3affe4e0e2 100644 --- a/test/master.html +++ b/test/master.html @@ -1,3 +1,7 @@ -