[Swift-commit] r4131 - in SwiftApps/SwiftR/Swift: R exec
noreply at svn.ci.uchicago.edu
noreply at svn.ci.uchicago.edu
Mon Feb 21 18:06:43 CST 2011
Author: tga
Date: 2011-02-21 18:06:43 -0600 (Mon, 21 Feb 2011)
New Revision: 4131
Modified:
SwiftApps/SwiftR/Swift/R/Workers.R
SwiftApps/SwiftR/Swift/exec/start-swift
Log:
Made swift logging far less verbose by default. Added an option to reenable it for debugging purposes.
Modified: SwiftApps/SwiftR/Swift/R/Workers.R
===================================================================
--- SwiftApps/SwiftR/Swift/R/Workers.R 2011-02-21 23:38:51 UTC (rev 4130)
+++ SwiftApps/SwiftR/Swift/R/Workers.R 2011-02-22 00:06:43 UTC (rev 4131)
@@ -5,7 +5,8 @@
parEnv=NULL, kernel=NULL, workmode=NULL,
throttle=NULL, queue=NULL,
rcmd=NULL, time=NULL,
- workerLogging=NULL,keepworkdir=NULL)
+ workerLogging=NULL,swiftLogging=NULL,
+ keepworkdir=NULL)
{
# server: which server backend to use to acquire workers
# for example, local runs tasks on the local machine
@@ -161,6 +162,12 @@
cmdString <- paste(cmdString, "-w", shQuote(workerLogging))
}
+ if(is.null(swiftLogging))
+ swiftLogging <- getOption("swift.swiftLogging")
+ if( (! is.null(swiftLogging)) && swiftLogging ) {
+ cmdString <- paste(cmdString, "-L")
+ }
+
if(is.null(keepworkdir))
keepworkdir <- getOption("swift.keepworkdir")
if(!is.null(keepworkdir) && keepworkdir)
Modified: SwiftApps/SwiftR/Swift/exec/start-swift
===================================================================
--- SwiftApps/SwiftR/Swift/exec/start-swift 2011-02-21 23:38:51 UTC (rev 4130)
+++ SwiftApps/SwiftR/Swift/exec/start-swift 2011-02-22 00:06:43 UTC (rev 4131)
@@ -445,6 +445,7 @@
kernel=NONE
workdir=NONE
workerLogging=ERROR
+swiftLoggingFlag="-minimal.logging"
keepdir=FALSE
rcmd=ssh # rcmd: ssh (typical) or qrsh (eg for siraf with node login restrictions)
@@ -466,6 +467,7 @@
-s) server=$2; verify-is-one-of server $server local ssh pbs pbsf sge cobalt; shift ;;
-t) time=$2; verify-not-null time $time; shift ;;
-w) workerLogging=$2; verify-is-one-of workerLoggingLevel $workerLogging NONE ERROR WARN INFO DEBUG TRACE; shift ;;
+ -L) swiftLoggingFlag="" ;; # swift default is lots of logging
-k) keepdir=TRUE ;;
--trace) set -x ;;
-d) workdir=$2; verify-not-null workdir $workdir; shift ;;
@@ -656,6 +658,6 @@
fi
-$SWIFTRBIN/../swift/bin/swift -config cf -tc.file tc -sites.file sites.xml $script -pipedir=$(pwd) >& $out </dev/null
+$SWIFTRBIN/../swift/bin/swift $swiftLoggingFlag -config cf -tc.file tc -sites.file sites.xml $script -pipedir=$(pwd) >& $out </dev/null
# Do any cleanup if swift exits in this manner
More information about the Swift-commit
mailing list