From 51c652640f0c4a02a831325aa25edd0a46d149e9 Mon Sep 17 00:00:00 2001 From: David Anderson Date: Fri, 13 May 2011 18:40:10 +0000 Subject: [PATCH] - create_work: allow multiple URLs for non-local input files (from Zoltan Farkas) - scheduler: fix message describing per-app limits svn path=/trunk/boinc/; revision=23546 --- checkin_notes | 13 ++++++++++++- html/project.sample/project.inc | 4 ---- sched/sched_main.cpp | 9 ++++++--- tools/backend_lib.cpp | 17 ++++++++++++++--- 4 files changed, 32 insertions(+), 11 deletions(-) diff --git a/checkin_notes b/checkin_notes index 31d2bc23df..602523a182 100644 --- a/checkin_notes +++ b/checkin_notes @@ -2957,4 +2957,15 @@ Charlie 13 May 2011 lib/ filesys.cpp - \ No newline at end of file + +David 13 May 2011 + - create_work: allow multiple URLs for non-local input files + (from Zoltan Farkas) + - scheduler: fix message describing per-app limits + + sched/ + sched_main.cpp + tools/ + backend_lib.cpp + html/project.sample/ + project.inc diff --git a/html/project.sample/project.inc b/html/project.sample/project.inc index 5e782281c8..511570a9fe 100644 --- a/html/project.sample/project.inc +++ b/html/project.sample/project.inc @@ -28,10 +28,6 @@ define("UOTD_ADMIN_EMAIL", "admin@$master_url"); // offensive forum posts. define("POST_REPORT_EMAILS", "moderator1@$master_url|moderator2@$master_url"); -// set the following var if your project is behind a proxy. -// This is used on ops/index.php to get the current SVN rev from BOINC -//$project_http_proxy = "tcp://proxyname:port" - // set the following if SVN requires specific configuration (e.g. proxy) // Used on ops/index.php. // define("SVN_CONFIG_DIRECTORY", "/home/boincadm/.subversion/"); diff --git a/sched/sched_main.cpp b/sched/sched_main.cpp index e078943b4e..e3bf1c03b0 100644 --- a/sched/sched_main.cpp +++ b/sched/sched_main.cpp @@ -629,12 +629,15 @@ void JOB_LIMIT::print_log() { } void JOB_LIMITS::print_log() { - log_messages.printf(MSG_NORMAL, "[quota] Overall limit on jobs in progress:\n"); + log_messages.printf(MSG_NORMAL, "[quota] Overall limits on jobs in progress:\n"); project_limits.print_log(); for (unsigned int i=0; iapps[i]; - log_messages.printf(MSG_NORMAL, "Limits for %s:\n", app->name); + APP* app = ssp->lookup_app_name(app_limits[i].app_name); + if (!app) continue; + log_messages.printf(MSG_NORMAL, + "[quota] Limits for %s:\n", app->name + ); app_limits[i].print_log(); } } diff --git a/tools/backend_lib.cpp b/tools/backend_lib.cpp index 8cc0452523..6d24ea8a89 100644 --- a/tools/backend_lib.cpp +++ b/tools/backend_lib.cpp @@ -24,6 +24,7 @@ #include #include #include +#include #include #include #include @@ -197,6 +198,7 @@ static int process_wu_template( out = ""; for (p=strtok(tmplate, "\n"); p; p=strtok(0, "\n")) { if (match_tag(p, "")) { + vector urls; bool generated_locally = false; file_number = nbytesdef = -1; md5str = urlstr = ""; @@ -209,6 +211,7 @@ static int process_wu_template( } else if (parse_bool(p, "generated_locally", generated_locally)) { continue; } else if (parse_str(p, "", urlstr)) { + urls.push_back(urlstr); continue; } else if (parse_str(p, "", md5str)) { continue; @@ -243,6 +246,8 @@ static int process_wu_template( infiles[file_number] ); } else if (nbytesdef == -1) { + // here if nybtes was not supplied; stage the file + // dir_hier_path( infiles[file_number], config_loc.download_dir, config_loc.uldl_dir_fanout, path, true @@ -264,8 +269,7 @@ static int process_wu_template( if (retval) { fprintf(stderr, "process_wu_template: md5_file %d\n", retval); return retval; - } - else if (config_loc.cache_md5_info) { + } else if (config_loc.cache_md5_info) { write_md5_info(path, md5, nbytes); } } @@ -286,9 +290,16 @@ static int process_wu_template( nbytes ); } else { + // here if nbytes etc. was supplied, + // i.e the file is already staged, possibly remotely + // + urlstr = ""; + for (unsigned int i=0; i\n"; + } sprintf(buf, " %s\n" - " %s\n" + "%s" " %s\n" " %.0f\n" "\n",