The last two messages have had several portions with no carriage returns.
Windows systems require both /r and /n in order to generate a new line in
the text.
jm7
boinc_cvs-request
@ssl.berkeley.edu
Sent by: To
boinc_cvs-bounces [email protected]
@ssl.berkeley.edu cc
Subject
09/17/2009 01:57 boinc_cvs Digest, Vol 58, Issue 28
PM
Please respond to
[email protected]
keley.edu
Send boinc_cvs mailing list submissions to
[email protected]
To subscribe or unsubscribe via the World Wide Web, visit
http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_cvs
or, via email, send a message with subject or body 'help' to
[email protected]
You can reach the person managing the list at
[email protected]
When replying, please edit your Subject line so it is more specific
than "Re: Contents of boinc_cvs digest..."
Today's Topics:
1. r19076 - branches/boinc_core_release_6_10
([email protected])
2. r19077 - tags ([email protected])
3. r19078 - in trunk/boinc: . client ([email protected])
4. r19079 - in trunk/boinc: . sched ([email protected])
----------------------------------------------------------------------
Message: 1
Date: Thu, 17 Sep 2009 08:32:34 -0700
From: [email protected]
Subject: [boinc_cvs] r19076 - branches/boinc_core_release_6_10
To: [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=UTF-8
Author: romw
Date: 2009-09-17 08:32:33 -0700 (Thu, 17 Sep 2009)
New Revision: 19076
Modified:
branches/boinc_core_release_6_10/checkin_notes
branches/boinc_core_release_6_10/configure.ac
branches/boinc_core_release_6_10/version.h
Log:
- Tag for 6.10.5 release, all platforms
boinc_core_release_6_10_5
/
configure.ac
version.h
Modified: branches/boinc_core_release_6_10/checkin_notes
===================================================================
--- branches/boinc_core_release_6_10/checkin_notes 2009-09-17
15:30:56 UTC (rev 19075)
+++ branches/boinc_core_release_6_10/checkin_notes 2009-09-17
15:32:33 UTC (rev 19076)
@@ -7482,3 +7482,12 @@
client/
log_flags.cpp,h
schedule_op.cpp
+
+Rom 17 Sept 2009
+ - Tag for 6.10.5 release, all platforms
+ boinc_core_release_6_10_5
+
+ /
+ configure.ac
+ version.h
+
Modified: branches/boinc_core_release_6_10/configure.ac
===================================================================
--- branches/boinc_core_release_6_10/configure.ac 2009-09-17
15:30:56 UTC (rev 19075)
+++ branches/boinc_core_release_6_10/configure.ac 2009-09-17
15:32:33 UTC (rev 19076)
@@ -6,7 +6,7 @@
AC_PREREQ(2.57)
dnl Set the BOINC version here. You can also use the set-version script.
-AC_INIT(BOINC, 6.10.4)
+AC_INIT(BOINC, 6.10.5)
LIBBOINC_VERSION=`echo ${PACKAGE_VERSION} | sed 's/\./:/g'`
AC_SUBST([LIBBOINC_VERSION])
Modified: branches/boinc_core_release_6_10/version.h
===================================================================
--- branches/boinc_core_release_6_10/version.h 2009-09-17 15:30:56
UTC (rev 19075)
+++ branches/boinc_core_release_6_10/version.h 2009-09-17 15:32:33
UTC (rev 19076)
@@ -10,10 +10,10 @@
#define BOINC_MINOR_VERSION 10
/* Release part of BOINC version number */
-#define BOINC_RELEASE 4
+#define BOINC_RELEASE 5
/* String representation of BOINC version number */
-#define BOINC_VERSION_STRING "6.10.4"
+#define BOINC_VERSION_STRING "6.10.5"
/* Package is a pre-release (Alpha/Beta) package */
/* #define BOINC_PRERELEASE 1 */
@@ -29,13 +29,13 @@
#define PACKAGE_NAME "BOINC"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "BOINC 6.10.4"
+#define PACKAGE_STRING "BOINC 6.10.5"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "boinc"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "6.10.4"
+#define PACKAGE_VERSION "6.10.5"
#endif /* #if (defined(_WIN32) || defined(__APPLE__)) */
------------------------------
Message: 2
Date: Thu, 17 Sep 2009 08:42:13 -0700
From: [email protected]
Subject: [boinc_cvs] r19077 - tags
To: [email protected], [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=UTF-8
Author: romw
Date: 2009-09-17 08:42:13 -0700 (Thu, 17 Sep 2009)
New Revision: 19077
Added:
tags/boinc_core_release_6_10_5/
Log:
Copied: tags/boinc_core_release_6_10_5 (from rev 19076,
branches/boinc_core_release_6_10)
------------------------------
Message: 3
Date: Thu, 17 Sep 2009 09:46:22 -0700
From: [email protected]
Subject: [boinc_cvs] r19078 - in trunk/boinc: . client
To: [email protected]
Message-ID: <[email protected]>
Content-Type: text/plain; charset=UTF-8
Author: davea
Date: 2009-09-17 09:46:21 -0700 (Thu, 17 Sep 2009)
New Revision: 19078
Modified:
trunk/boinc/checkin_notes
trunk/boinc/client/scheduler_op.cpp
Log:
- client: if project-supplied backoff > 28 days, cap rather than ignore
Modified: trunk/boinc/checkin_notes
===================================================================
--- trunk/boinc/checkin_notes 2009-09-17 15:42:13 UTC (rev 19077)
+++ trunk/boinc/checkin_notes 2009-09-17 16:46:21 UTC (rev 19078)
@@ -7772,7 +7772,7 @@
client/
log_flags.cpp,h
- schedule_op.cpp
+ scheduler_op.cpp
Charlie 17 Sept 2009
- Mac installer: create a new command-line tool AddRemoveUser to add
users
@@ -7786,3 +7786,9 @@
mac_build/
boinc.xcodeproj/
project.pbxproj
+
+David 17 Sept 2009
+ - client: if project-supplied backoff > 28 days, cap rather than
ignore
+
+ client/
+ scheduler_op.cpp
Modified: trunk/boinc/client/scheduler_op.cpp
===================================================================
--- trunk/boinc/client/scheduler_op.cpp 2009-09-17 15:42:13 UTC
(rev 19077)
+++ trunk/boinc/client/scheduler_op.cpp 2009-09-17 16:46:21 UTC
(rev 19078)
@@ -834,15 +834,15 @@
if (!retval) auto_update.present = true;
#endif
} else if (parse_double(buf, "<cpu_backoff>", cpu_backoff)) {
- if (cpu_backoff > 28*SECONDS_PER_DAY) cpu_backoff = 0;
+ if (cpu_backoff > 28*SECONDS_PER_DAY) cpu_backoff =
28*SECONDS_PER_DAY;
if (cpu_backoff < 0) cpu_backoff = 0;
continue;
} else if (parse_double(buf, "<cuda_backoff>", cuda_backoff)) {
- if (cuda_backoff > 28*SECONDS_PER_DAY) cuda_backoff = 0;
+ if (cuda_backoff > 28*SECONDS_PER_DAY) cuda_backoff =
28*SECONDS_PER_DAY;
if (cuda_backoff < 0) cuda_backoff = 0;
continue;
} else if (parse_double(buf, "<ati_backoff>", ati_backoff)) {
- if (ati_backoff > 28*SECONDS_PER_DAY) ati_backoff = 0;
+ if (ati_backoff > 28*SECONDS_PER_DAY) ati_backoff =
28*SECONDS_PER_DAY;
if (ati_backoff < 0) ati_backoff = 0;
continue;
} else if (match_tag(buf, "<!--")) {------------------------------
Message: 4Date: Thu, 17 Sep 2009 10:56:59 -0700From:
[email protected]: [boinc_cvs] r19079 - in trunk/boinc: .
schedTo: [email protected]:
<[email protected]>Content-Type:
text/plain; charset=UTF-8Author: daveaDate: 2009-09-17 10:56:59 -0700 (Thu,
17 Sep 2009)New Revision: 19079Added: trunk/boinc/generate_svn_version.sh
Modified: trunk/boinc/Makefile.am trunk/boinc/checkin_notes
trunk/boinc/sched/census.cpp trunk/boinc/sched/db_dump.cpp
trunk/boinc/sched/db_purge.cpp trunk/boinc/sched/delete_file.cpp
trunk/boinc/sched/feeder.cpp trunk/boinc/sched/file_deleter.cpp
trunk/boinc/sched/file_upload_handler.cpp trunk/boinc/sched/get_file.cpp
trunk/boinc/sched/make_work.cpp trunk/boinc/sched/message_handler.cpp
trunk/boinc/sched/request_file_list.cpp
trunk/boinc/sched/sample_work_generator.cpp
trunk/boinc/sched/sched_driver.cpp trunk/boinc/sched/sched_main.cpp
trunk/boinc/sched/send_file.cpp trunk/boinc/sched/show_shmem.cpp
trunk/boinc/sched/start trunk/boinc/sched/transitioner.cpp
trunk/boinc/sched/trickle_handler.cpp trunk/boinc/sched/update_stats.cpp
trunk/boinc/sched/wu_check.cppLog:- server programs: add --help and
--version cmdline options to all. From Nils Chr. Brause.Modified:
trunk/boinc/Makefile.am
===================================================================---
trunk/boinc/Makefile.am 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/Makefile.am 2009-09-17 17:56:59 UTC (rev 19079)@@ -39,9 +39,17
@@ if INSTALL_HEADERS pkginclude_HEADERS = \- version.h+ version.h \
+ svn_version.h endif +# svn_version.h should always be rebuilt.+
+BUILT_SOURCES = svn_version.h+svn_version.h: generate_svn_version.sh+ sh
generate_svn_version.sh+.PHONY: svn_version.h+ # Add a stage target for
staging a distribution clean-generic:Modified: trunk/boinc/checkin_notes
===================================================================---
trunk/boinc/checkin_notes 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/checkin_notes 2009-09-17 17:56:59 UTC (rev 19079)@@ -7792,3
+7792,12 @@ client/ scheduler_op.cpp++David 17 Sept 2009+
- server programs: add --help and --version cmdline options to all.+
>From Nils Chr. Brause.++ Makefile.am+ generate_svn_version.sh+
sched/+ (most).cppAdded: trunk/boinc/generate_svn_version.sh
Modified: trunk/boinc/sched/census.cpp
===================================================================---
trunk/boinc/sched/census.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/census.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@ -28,8
+28,9 @@ #include "sched_util.h" #include "sched_msgs.h" #include
"hr_info.h"+#include "svn_version.h" -void usage(char** argv) {+void usage
(char *name) { fprintf(stderr, "This program scans the 'host'
DB table and creates two files:\n\n" "%s: how much RAC each HR
class is getting\n"@@ -38,20 +39,34 @@ " (needed if you use the
'job_size_matching' scheduling option).\n\n" "This should be run as
a periodic task (about once a day) from config.xml.\n" "For more
info, see http://boinc.berkeley.edu/trac/wiki/HomogeneousRedundancy\n\n"-
"Usage: %s [--help]\n",- HR_INFO_FILENAME, PERF_INFO_FILENAME, argv
[0]+ "Usage: %s [OPTION]...\n\n"+ "Options:\n"+ " -h
--help shows this help text.\n"+ " -v --version shows version
information.\n",+ HR_INFO_FILENAME, PERF_INFO_FILENAME, name );-
exit(0); } int main(int argc, char** argv) { HR_INFO hri; int
retval; - for (int i=0; i<argc; i++) {+ for (int i=1; i<argc; i+
+) { if (!strcmp(argv[i], "--help") || !strcmp(argv[i], "-h")) {-
usage(argv);+ usage(argv[0]);+ exit(0); }+
else if(!strcmp(argv[i], "--version") || !strcmp(argv[i], "-v")) {+
printf("%s\n", SVN_VERSION);+ exit(0);+ }+ else {+
log_messages.printf(MSG_CRITICAL,+ "unknown command line
argument: %s\n\n", argv[i]+ );+ usage(argv[0]);+
exit(1);+ } } check_stop_daemons(); retval =
config.parse_file();Modified: trunk/boinc/sched/db_dump.cpp
===================================================================---
trunk/boinc/sched/db_dump.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/db_dump.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@ -40,6
+40,7 @@ #include "error_numbers.h" #include "md5_file.h" #include
"parse.h"+#include "svn_version.h" #include "sched_config.h" #include
"sched_util.h"@@ -736,20 +737,20 @@ return 0; } -void usage(char**
argv) {+void usage(char* name) { fprintf(stderr, "This program
generates XML files containing project statistics.\n" "It should be
run once a day as a periodic task in config.xml.\n" "For more info,
see http://boinc.berkeley.edu/trac/wiki/DbDump\n\n
http://www.gnu.org/licenses/>. -// sample_work_generator.C: an example
BOINC work generator.+// sample_work_generator.cpp: an example BOINC work
generator. // This work generator has the following properties // (you may
need to change some or all of these): //@@ -37,6 +37,7 @@ #include
"backend_lib.h" #include "parse.h" #include "util.h"+#include
"svn_version.h" #include "sched_config.h" #include "sched_util.h"@@
-137,16 +138,47 @@ } } +void usage(char *name) {+ fprintf(stderr,
"This is an example BOINC work generator.\n"+ "This work generator
has the following properties\n"+ "(you may need to change some or
all of these):\n"+ "- Runs as a daemon, and creates an unbounded
supply of work.\n"+ " It attempts to maintain a \"cushion\" of 100
unsent job instances.\n"+ " (your app may not work this way; e.g.
you might create work in batches)\n"+ "- Creates work for the
application \"uppercase\".\n"+ "- Creates a new input file for each
job;\n"+ " the file (and the workunit names) contain a timestamp\n"
+ " and sequence number, so that they're unique.\n\n"+
"Usage: %s [OPTION]...\n\n"+ "Options:\n"+ " [ -d X ]
Sets debug level to X.\n"+ " [ -h | -help | --help ] Shows
this help text.\n"+ " [ -v | --version | --version ] Shows version
information.\n",+ name+ );+}+ int main(int argc, char** argv) {
int i, retval; for (i=1; i<argc; i++) { if (!strcmp(argv[i],
"-d")) {- log_messages.set_debug_level(atoi(argv[++i]));+
if(!argv[++i]) {+ log_messages.printf(MSG_CRITICAL, "%s
requires an argument\n\n", argv[--i]);+ usage(argv[0]);+
exit(1);+ }+ log_messages.set_debug_level(atoi(argv
[i]));+ } else if(!strcmp(argv[i], "-h") || !strcmp(argv[i],
"-help") || !strcmp(argv[i], "--help")) {+ usage(argv[0]);+
exit(0);+ } else if(!strcmp(argv[i], "-v") || !strcmp(argv[i],
"-version") || !strcmp(argv[i], "--version")) {+ printf("%s\n",
SVN_VERSION);+ exit(0); } else {-
log_messages.printf(MSG_CRITICAL,- "bad cmdline arg: %s",
argv[i]- );+ log_messages.printf(MSG_CRITICAL,
"unknown command line argument: %s\n\n", argv[i]);+ usage(argv
[0]);+ exit(1); } } Modified:
trunk/boinc/sched/sched_driver.cpp
===================================================================---
trunk/boinc/sched/sched_driver.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/sched_driver.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-43,6 +43,7 @@ #include <cstdio> #include <vector> #include "util.h"
+#include "svn_version.h" using std::vector; @@ -117,18 +118,64 @@ );
} +void usage(char *name) {+ fprintf(stderr,+ "This program
generates a stream of scheduler requests;\n"+ "it acts as a \"driver
\" for the scheduler when used as:\n"+ "%s | cgi --batch
--mark_jobs_done\n\n"+ "This was written to test the homogeneous
redundancy features\n"+ "of the feeder and scheduler,\n"+
"but it could be used for a variety of other purposes.\n\n"+ "Each
request asks for a uniformly-distributed random amount of work.\n"+
"The OS and CPU info is taken from the successive lines of a file of the
form\n"+ "| os_name | p_vendor | p_model |\n"+ "Generate this
file with a SQL query, trimming off the start and end.\n\n"+ "
Notes:\n"+ "1) Use sample_trivial_validator and
sample_dummy_assimilator\n"+ "2) Edit the following to something in
your DB\n\n"+ "Usage: %s [OPTION]...\n\n"+ "Options: \n"+
" --nrequests N Sets the total nukmer of requests to N\n"
+ " --reqs_per_second X Sets the number of requests per
second to X\n"+ " [ -h | -help | --help ] Show this help
text.\n"+ " [ -v | -version | --version ] Show version information
\n",+ name+ );+}+ int main(int argc, char** argv) { int i,
nrequests = 1; double reqs_per_second = 1; for (i=1; i<argc; i++)
{ if (!strcmp(argv[i], "--nrequests")) {- nrequests =
atoi(argv[++i]);- continue;+ if(!argv[++i]) {+
fprintf(stderr, "%s requires an argument\n\n", argv[--i]);+
usage(argv[0]);+ exit(1);+ }+
nrequests = atoi(argv[i]); }- if (!strcmp(argv[i],
"--reqs_per_second")) {- reqs_per_second = atof(argv[++i]);+
else if (!strcmp(argv[i], "--reqs_per_second")) {+ if(!argv[+
+i]) {+ fprintf(stderr, "%s requires an argument\n\n", argv
[--i]);+ usage(argv[0]);+ exit(1);
+ }+ reqs_per_second = atof(argv[i]); }+
else if(!strcmp(argv[i], "-h") || !strcmp(argv[i], "-help") || !strcmp(argv
[i], "--help")) {+ usage(argv[0]);+ exit(0);
+ }+ else if(!strcmp(argv[i], "-v") || !strcmp(argv[i],
"-version") || !strcmp(argv[i], "--version")) {+ printf("%s\n",
SVN_VERSION);+ exit(0);+ } else {+ fprintf
(stderr, "unknown command line argument: %s\n\n", argv[i]);+
usage(argv[0]);+ exit(1);+ } } read_hosts();
double t1, t2, x;Modified: trunk/boinc/sched/sched_main.cpp
===================================================================---
trunk/boinc/sched/sched_main.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/sched_main.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-51,6 +51,7 @@ #include "util.h" #include "str_util.h" #include "synch.h"
+#include "svn_version.h" #include "sched_config.h" #include
"sched_types.h"@@ -84,18 +85,19 @@ static void usage(char* p) {
fprintf(stderr,- "usage: %s [options]\n"- "\n"-
"--batch stdin contains a sequence of request messages.\n"-
" Do them all, and ignore rpc_seqno.\n"-
"--mark_jobs_done When send a job, also mark it as done.\n"-
" (for performance testing)\n"- "--debug_log
Write messages to the file 'debug_log'\n"- "--simulator X Start
with simulated time X\n"- " (only if compiled with
GCL_SIMULATOR)\n",+ "Usage: %s [OPTION]...\n\n"+ "Options:\n"
+ " --batch stdin contains a sequence of request
messages.\n"+ " Do them all, and ignore
rpc_seqno.\n"+ " --mark_jobs_done When send a job, also mark it
as done.\n"+ " (for performance testing)\n"+
" --debug_log Write messages to the file 'debug_log'\n"+ "
--simulator X Start with simulated time X\n"+
" (only if compiled with GCL_SIMULATOR)\n"+ "
-h | --help Show this help text\n"+ " -v | --version
Show version information\n", p );- exit(1); } void
debug_sched(const char *trigger) {@@ -363,10 +365,23 @@
debug_log = true; #ifdef GCL_SIMULATOR } else if (!strcmp(argv[i],
"--simulator")) {- simtime = atof(argv[++i]);+ if
(!argv[++i]) {+ log_messages.printf(MSG_CRITICAL, "%s
requires an argument\n\n", argv[--i]);+ usage(argv[0]);+
exit(1);+ }+ simtime = atof(argv[i]); #endif
+ } else if(!strcmp(argv[1], "-h") || !strcmp(argv[1], "--help")) {+
usage(argv[0]);+ exit(0);+ } else if(!strcmp(argv[1],
"-v") || !strcmp(argv[1], "--version")) {+ printf("%s\n",
SVN_VERSION);+ exit(0); } else {+
log_messages.printf(MSG_CRITICAL, "unknown command line argument: %s\n\n",
argv[i]); usage(argv[0]);+ exit(1); } }
Modified: trunk/boinc/sched/send_file.cpp
===================================================================---
trunk/boinc/sched/send_file.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/send_file.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-17,7 +17,7 @@ //------------------------------------ //-// send_file
[-host_id host_id] [-file_name file_name] [-num_copies]+// send_file
[-host_id host_id] [-file_name file_name] // -host_id name of
host to upload from // -file_name name of specific file, dominates
workunit //@@ -36,6 +36,7 @@ #include "util.h" #include "str_util.h"
#include "md5_file.h"+#include "svn_version.h" #include "sched_config.h"
#include "sched_util.h"@@ -152,39 +153,57 @@ } +void usage(char *name) {+
fprintf(stderr,+ "Create a result entries, initialized to sent, and
corresponding\n"+ "messages to the get the files.\n\n"+
"Usage: %s [OPTION]...\n\n"+ "Options:\n"+ " -host_id id
id of host to upload from\n"+ " -file_name name name
of specific file, dominates workunit\n"+ " [ -h | -help | --help ]
Show this help text.\n"+ " [ -v | -version | --version ] Show
version information.\n",+ name+ );+}+ int main(int argc, char**
argv) { int i, retval; char file_name[256]; int host_id;-
int num_copies; // initialize argument strings to empty strcpy
(file_name, ""); host_id = 0;- num_copies = 0;
check_stop_daemons(); // get arguments- for(i=1; i<argc; i++) {+
for (i=1; i<argc; i++) { if (!strcmp(argv[i], "-host_id")) {-
host_id = atoi(argv[++i]);+ if(!argv[++i]) {+
fprintf(stderr, "%s requires an argument\n\n", argv[--i]);+
usage(argv[0]);+ exit(1);+ }+ host_id
= atoi(argv[i]); } else if (!strcmp(argv[i], "-file_name")) {-
strcpy(file_name, argv[++i]);- } else if (!strcmp(argv[i], "-help"))
{- fprintf(stdout,- "send_file: sends a file
to a specific host\n\n"- "It takes the following
arguments and types:\n"- "-hostid (int); the number of
the host\n"- "-file_name (string); the name of the file
to send\n"- );+ if(!argv[++i]) {+
fprintf(stderr, "%s requires an argument\n\n", argv[--i]);+
usage(argv[0]);+ exit(1);+ }+ strcpy
(file_name, argv[i]);+ } else if(!strcmp(argv[i], "-h") || !strcmp
(argv[i], "-help") || !strcmp(argv[i], "--help")) {+ usage(argv
[0]); exit(0);+ } else if(!strcmp(argv[i], "-v")
|| !strcmp(argv[i], "-version") || !strcmp(argv[i], "--version")) {+
printf("%s\n", SVN_VERSION);+ exit(0); } else {-
if (!strncmp("-",argv[i],1)) {- fprintf(stderr, "send_file:
bad argument '%s'\n", argv[i]);- fprintf(stderr, "type
send_file -help for more information\n");- exit(1);
- }+ fprintf(stderr, "unknowen command line argument:
%s\n\n", argv[i]);+ usage(argv[0]);+ exit(1);
} } Modified: trunk/boinc/sched/show_shmem.cpp
===================================================================---
trunk/boinc/sched/show_shmem.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/show_shmem.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-27,12 +27,39 @@ #include "sched_config.h" #include "sched_shmem.h"
#include "str_util.h"+#include "svn_version.h" -int main() {+void usage
(char *name) {+ fprintf(stderr,+ "Displays the work_item part of
shared-memory structure.\n\n"+ "Usage: %s [OPTION]\n\n"+
"Options:\n"+ " [ -h | -help | --help ] Show this help
text.\n"+ " [ -v | -version | --version ] Shows version
information.\n",+ name+ );+}++int main(int argc, char *argv[]) {
SCHED_SHMEM* ssp; int retval; void* p; + for (int c = 1; c <
argc; c++) {+ std::string option(argv[c]);+ if(option == "-h"
|| option == "-help" || option == "--help") {+ usage(argv[0]);+
exit(0);+ } else if(option == "-v" || option == "-version" || option
== "--version") {+ printf("%s\n", SVN_VERSION);+ exit
(0);+ } else {+ fprintf(stderr, "unknown command line
argument: %s\n\n", argv[c]);+ usage(argv[0]);+ exit
(1);+ }+ }+ retval = config.parse_file(); if (retval) {
printf("Can't parse config.xml: %s\n", boincerror(retval));Modified:
trunk/boinc/sched/start
===================================================================---
trunk/boinc/sched/start 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/start 2009-09-17 17:56:59 UTC (rev 19079)@@ -25,7 +25,8
@@ --disable (default if invoked as "stop") Set project
to DISABLED mode and stop daemons. - --status Show status.+ --status
(default if invoked as "status")+ Show status. See "start
--help" for options. @@ -644,6 +645,8 @@ print >>sys.stderr, "Based
on the invocation name as `start', the default action is --enable."
elif program_name == 'stop': print >>sys.stderr, "Based on the
invocation name as `stop', the default action is --disable."+ elif
program_name == 'status':+ print >>sys.stderr, "Based on the
invocation name as `status', the default action is --status." sys.exit
(1) config_filename = boinc_project_path.config_xml_filenameModified:
trunk/boinc/sched/transitioner.cpp
===================================================================---
trunk/boinc/sched/transitioner.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/transitioner.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-42,6 +42,7 @@ #include "common_defs.h" #include "error_numbers.h" #include
"str_util.h"+#include "svn_version.h" #include "sched_config.h" #include
"sched_util.h"@@ -434,23 +435,23 @@ // all_over_and_validated =
true; bool all_over_and_ready_to_assimilate = true; // used for the
defer assmilation- int most_recently_returned = 0;+ int
most_recently_returned = 0; for (i=0; i<items.size(); i++) {
TRANSITIONER_ITEM& res_item = items[i]; if (res_item.res_id) {
if (res_item.res_server_state == RESULT_SERVER_STATE_OVER) {-
if ( res_item.res_received_time > most_recently_returned ) {-
most_recently_returned = res_item.res_received_time;- }+
if ( res_item.res_received_time > most_recently_returned ) {+
most_recently_returned = res_item.res_received_time;+ }
if (res_item.res_outcome == RESULT_OUTCOME_SUCCESS) {
if (res_item.res_validate_state == VALIDATE_STATE_INIT) {
all_over_and_validated = false;
all_over_and_ready_to_assimilate = false; }
} else if ( res_item.res_outcome == RESULT_OUTCOME_NO_REPLY ) {-
if ( ( res_item.res_report_deadline +
config.grace_period_hours*60*60 ) > now ) {-
all_over_and_validated = false;- }+
if ( ( res_item.res_report_deadline + config.grace_period_hours*60*60 ) >
now ) {+ all_over_and_validated = false;
+ } } } else {
all_over_and_validated = false;@@ -466,7 +467,7 @@ // if
(all_over_and_ready_to_assimilate == true && wu_item.assimilate_state ==
ASSIMILATE_INIT && items.size() > 0 && wu_item.canonical_resultid > 0 )
{- wu_item.assimilate_state = ASSIMILATE_READY;+
wu_item.assimilate_state = ASSIMILATE_READY; log_messages.printf
(MSG_NORMAL, "[WU#%d %s] Deferred assimililation now set to
ASSIMILATE_STATE_READY\n", wu_item.id, wu_item.name@@ -526,7
+527,7 @@ } } } else if ( wu_item.assimilate_state
== ASSIMILATE_DONE ) {- log_messages.printf(MSG_DEBUG,+
log_messages.printf(MSG_DEBUG, "[WU#%d %s] not checking for
items to be ready for delete because the deferred delete time has not
expired. That will occur in %d seconds\n", wu_item.id,
wu_item.name,@@ -566,30 +567,33 @@
wu_item.transition_time = x; } } else if
( res_item.res_server_state == RESULT_SERVER_STATE_OVER ) {-
if ( res_item.res_outcome == RESULT_OUTCOME_NO_REPLY ) {-
// Transition again after the grace period has expired- if
( ( res_item.res_report_deadline + config.grace_period_hours*60*60 ) >
now ) {- x = res_item.res_report_deadline +
config.grace_period_hours*60*60;- if (x >
max_grace_or_delay_time) {-
max_grace_or_delay_time = x;- }-
}- } else if ( res_item.res_outcome ==
RESULT_OUTCOME_SUCCESS || res_item.res_outcome ==
RESULT_OUTCOME_CLIENT_ERROR || res_item.res_outcome ==
RESULT_OUTCOME_VALIDATE_ERROR) {- // Transition again
after deferred delete period has experied- if
( (res_item.res_received_time + config.delete_delay_hours*60*60) > now ) {-
x = res_item.res_received_time +
config.delete_delay_hours*60*60;- if (x >
max_grace_or_delay_time && res_item.res_received_time > 0) {-
max_grace_or_delay_time = x;-
}- }+ if ( res_item.res_outcome ==
RESULT_OUTCOME_NO_REPLY ) {+ // Transition again after
the grace period has expired+ //+ if
((res_item.res_report_deadline + config.grace_period_hours*60*60) > now) {+
x = res_item.res_report_deadline + config.grace_period_hours*60*60;+
if (x > max_grace_or_delay_time) {+
max_grace_or_delay_time = x;+ }
+ }+ } else if (res_item.res_outcome ==
RESULT_OUTCOME_SUCCESS || res_item.res_outcome ==
RESULT_OUTCOME_CLIENT_ERROR || res_item.res_outcome ==
RESULT_OUTCOME_VALIDATE_ERROR) {+ // Transition again
after deferred delete period has experied+ //+
if ((res_item.res_received_time + config.delete_delay_hours*60*60) > now) {
+ x = res_item.res_received_time +
config.delete_delay_hours*60*60;+ if (x >
max_grace_or_delay_time && res_item.res_received_time > 0) {+
max_grace_or_delay_time = x;+ }
+ } } } } }+
// If either of the grace period or delete delay is less than // the
next transition time then use that value //- if
( max_grace_or_delay_time < wu_item.transition_time &&
max_grace_or_delay_time > now && ninprogress == 0) {+ if
(max_grace_or_delay_time < wu_item.transition_time &&
max_grace_or_delay_time > now && ninprogress == 0) {
wu_item.transition_time = max_grace_or_delay_time;
log_messages.printf(MSG_NORMAL, "[WU#%d %s] Delaying transition
due to grace period or delete day. New transition time = %d sec\n",@@
-693,6 +697,24 @@ } } +void usage(char *name) {+ fprintf(stderr,+
"Handles transitions in the state of a WU\n"+ " - a result has
become DONE (via timeout or client reply)\n"+ " - the WU error mask
is set (e.g. by validater)\n"+ " - assimilation is finished\n\n"+
"Usage: %s [OPTION]...\n\n"+ "Options: \n"+ " [ -one_pass ]
do one pass, then exit\n"+ " [ -d x ] debug
level x\n"+ " [ -mod n i ] process only WUs with
(id mod n) == i\n"+ " [ -sleep_interval x ] sleep x
seconds if nothing to do\n"+ " [ -h | -help | --help ] Show
this help text.\n"+ " [ -v | -version | --version ] Shows version
information.\n",+ name+ );+}+ int main(int argc, char** argv) {
int i, retval; char path[256];@@ -702,13 +724,38 @@ if (!strcmp
(argv[i], "-one_pass")) { one_pass = true; } else if
(!strcmp(argv[i], "-d")) {- log_messages.set_debug_level(atoi
(argv[++i]));+ if(!argv[++i]) {+
log_messages.printf(MSG_CRITICAL, "%s requires an argument\n\n", argv
[--i]);+ usage(argv[0]);+ exit(1);
+ }+ log_messages.set_debug_level(atoi(argv[i]));
} else if (!strcmp(argv[i], "-mod")) {+ if(!argv[i+1] || !argv[i
+2]) {+ log_messages.printf(MSG_CRITICAL, "%s requires two
arguments\n\n", argv[i]);+ usage(argv[0]);+
exit(1);+ } mod_n = atoi(argv[++i]);
mod_i = atoi(argv[++i]); do_mod = true; } else if
(!strcmp(argv[i], "-sleep_interval")) {- sleep_interval = atoi
(argv[++i]);+ if(!argv[++i]) {+
log_messages.printf(MSG_CRITICAL, "%s requires an argument\n\n", argv
[--i]);+ usage(argv[0]);+ exit(1);
+ }+ sleep_interval = atoi(argv[i]);+ } else
if (!strcmp(argv[i], "-h") || !strcmp(argv[i], "-help") || !strcmp(argv[i],
"--help")) {+ usage(argv[0]);+ exit(0);+ }
else if (!strcmp(argv[i], "-v") || !strcmp(argv[i], "-version") || !strcmp
(argv[i], "--version")) {+ printf("%s\n", SVN_VERSION);+
exit(0);+ } else {+ log_messages.printf(MSG_CRITICAL,
"unknown command line argument: %s\n\n", argv[i]);+ usage(argv
[0]);+ exit(1); } } if (!one_pass)
check_stop_daemons();Modified: trunk/boinc/sched/trickle_handler.cpp
===================================================================---
trunk/boinc/sched/trickle_handler.cpp 2009-09-17 16:46:21 UTC (rev
19078)+++ trunk/boinc/sched/trickle_handler.cpp 2009-09-17 17:56:59 UTC
(rev 19079)@@ -35,6 +35,7 @@ #include "util.h" #include "error_numbers.h"
#include "str_util.h"+#include "svn_version.h" #include "sched_config.h"
#include "sched_util.h"@@ -137,6 +138,23 @@ return 0; } +void usage
(char *name) {+ fprintf(stderr,+ "Framework for trickle-up
message handler\n"+ "This program must be linked with an
app-specific function:\n\n"+ "int handle_trickle(MSG_FROM_HOST&)\n"+
" - handle a trickle message\n\n"+ "return nonzero on error\n\n"+
"Usage: %s [OPTION]...\n\n"+ "Options:\n"+ " -variety X
Set Variety to X\n"+ " [ -d X ] Set debug
level to X\n"+ " [ -one_pass ] Make one pass
through table, then exit\n"+ " [ -h | -help | --help ] Show
this help text\n"+ " [ -v | -version | --version ] Shows version
information\n",+ name+ );+} int main(int argc, char** argv) {
int i, retval;@@ -148,13 +166,29 @@ if (!strcmp(argv[i],
"-one_pass")) { one_pass = true; } else if (!strcmp
(argv[i], "-variety")) {- strcpy(variety, argv[++i]);+
if (!argv[++i]) {+ log_messages.printf(MSG_CRITICAL, "%s
requires an argument\n\n", argv[--i]);+ usage(argv[0]);+
exit(1);+ }+ strcpy(variety, argv[i]); } else
if (!strcmp(argv[i], "-d")) {- log_messages.set_debug_level(atoi
(argv[++i]));+ if (!argv[++i]) {+
log_messages.printf(MSG_CRITICAL, "%s requires an argument\n\n", argv
[--i]);+ usage(argv[0]);+ exit(1);
+ }+ log_messages.set_debug_level(atoi(argv[i]));
+ } else if (!strcmp(argv[i], "-v") || !strcmp(argv[i], "-version")
|| !strcmp(argv[i], "--version")) {+ printf("%s\n",
SVN_VERSION);+ exit(0);+ } else if (!strcmp(argv[i],
"-h") || !strcmp(argv[i], "-help") || !strcmp(argv[i], "--help")) {+
usage(argv[0]);+ exit(0); } else {-
log_messages.printf(MSG_CRITICAL,- "unrecognized arg: %s\n",
argv[i]- );+ log_messages.printf(MSG_CRITICAL,
"unknown command line argument: %s\n\n", argv[i]);+ usage(argv
[0]);+ exit(1); } } Modified:
trunk/boinc/sched/update_stats.cpp
===================================================================---
trunk/boinc/sched/update_stats.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/update_stats.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-36,6 +36,7 @@ #include "util.h" #include "str_util.h" #include
"error_numbers.h"+#include "svn_version.h" #include "sched_config.h"
#include "sched_util.h"@@ -177,6 +178,26 @@ return 0; } +void usage
(char *name) {+ fprintf(stderr,+ "Update average credit for idle
users, hosts and teams.\n"+ "These fields are updates as new credit
is granted;\n"+ "the purpose of this program is to decay credit of
entities\n"+ "that are inactive for long periods.\n"+ "Hence
it should be run about once a day at most.\n\n"+ "Also updates the
nusers field of teams\n\n"+ "Usage: %s [OPTION]...\n\n"+
"Options:\n"+ " [ -d X ] Set debug level to X
\n"+ " [ -update_teams ] Updates teams.\n"+
" [ -update_users ] Updates users.\n"+
" [ -update_hosts ] Updates hosts.\n"+ " [ -h | -help
| --help ] Shows this help text\n"+ " [ -v | -version |
--version ] Shows version information\n",+ name+ );+}+ int main
(int argc, char** argv) { int retval, i; bool do_update_teams =
false, do_update_users = false;@@ -194,9 +215,22 @@ } else if
(!strcmp(argv[i], "-update_hosts")) { do_update_hosts = true;
} else if (!strcmp(argv[i], "-d")) {-
log_messages.set_debug_level(atoi(argv[++i]));+ if (!argv[++i])
{+ log_messages.printf(MSG_CRITICAL, "%s requires an
argument\n\n", argv[--i]);+ usage(argv[0]);+
exit(1);+ }+ log_messages.set_debug_level(atoi(argv
[i]));+ } else if (!strcmp(argv[i], "-v") || !strcmp(argv[i],
"-version") || !strcmp(argv[i], "--version")) {+ printf("%s\n",
SVN_VERSION);+ exit(0);+ } else if (!strcmp(argv[i],
"-h") || !strcmp(argv[i], "-help") || !strcmp(argv[i], "--help")) {+
usage(argv[0]);+ exit(0); } else {-
log_messages.printf(MSG_CRITICAL, "Unrecognized arg: %s\n", argv[i]);+
log_messages.printf(MSG_CRITICAL, "unknown command line argument: %s\n\n",
argv[i]);+ usage(argv[0]);+ exit(1); } }
Modified: trunk/boinc/sched/wu_check.cpp
===================================================================---
trunk/boinc/sched/wu_check.cpp 2009-09-17 16:46:21 UTC (rev 19078)+++
trunk/boinc/sched/wu_check.cpp 2009-09-17 17:56:59 UTC (rev 19079)@@
-29,6 +29,7 @@ #include <string> #include "boinc_db.h"+#include
"svn_version.h" #include "parse.h" #include "util.h"@@ -99,11 +100,41 @@
return 0; } +void usage(char *name) {+ fprintf(stderr,+ "Looks
for results with missing input files\n\n"+ "Usage: %s [OPTION]\n\n"+
"Options:\n"+ " [ -repair ] change them to
server_state OVER,\n"+ " outcome
COULDNT_SEND\n"+ " [ -h | -help | --help ] Shows this help
text\n"+ " [ -v | -version | --version ] Shows version information
\n",+ name+ );+}+ int main(int argc, char** argv) { DB_RESULT
result; char clause[256]; int retval, n, nerr; + for(int c = 1;
c < argc; c++) {+ std::string option(argv[c]);+ if(option ==
"-h" || option == "-help" || option == "--help") {+ usage(argv
[0]);+ exit(0);+ } else if(option == "-v" || option ==
"-version" || option == "--version") {+ printf("%s\n",
SVN_VERSION);+ exit(0);+ } else if (option == "-repair")
{+ repair = true;+ } else {+ fprintf(stderr,
"unknown command line argument: %s\n\n", argv[c]);+ usage(argv
[0]);+ exit(1);+ }+ }+ retval = config.parse_file
(); if (retval) exit(1); @@ -112,7 +143,6 @@ printf
("boinc_db.open: %d\n", retval); exit(1); }- if (argc > 1
&& !strcmp(argv[1], "-repair")) repair = true; n = nerr = 0;
printf("Unsent results:\n");------------------------------
_______________________________________________boinc_cvs mailing list
[email protected]
http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_cvsEnd of boinc_cvs
Digest, Vol 58, Issue 28*****************************************
_______________________________________________
boinc_dev mailing list
[email protected]
http://lists.ssl.berkeley.edu/mailman/listinfo/boinc_dev
To unsubscribe, visit the above URL and
(near bottom of page) enter your email address.