[Swift-commit] r2899 - in trunk: . docs etc libexec src/org/griphyn/vdl/mapping src/org/griphyn/vdl/util
noreply at svn.ci.uchicago.edu
noreply at svn.ci.uchicago.edu
Tue May 5 11:19:12 CDT 2009
Author: benc
Date: 2009-05-05 11:19:12 -0500 (Tue, 05 May 2009)
New Revision: 2899
Modified:
trunk/CHANGES.txt
trunk/docs/userguide.xml
trunk/etc/swift.properties
trunk/libexec/vdl.k
trunk/src/org/griphyn/vdl/mapping/AbstractDataNode.java
trunk/src/org/griphyn/vdl/util/VDL2Config.java
trunk/src/org/griphyn/vdl/util/VDL2ConfigProperties.java
Log:
New configuration property provenance.log which controls whether verbose
provenance-related log information is recorded in the run log file or
not. By default, this is false, which means that less information is
output by default now than previously.
Modified: trunk/CHANGES.txt
===================================================================
--- trunk/CHANGES.txt 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/CHANGES.txt 2009-05-05 16:19:12 UTC (rev 2899)
@@ -1,3 +1,9 @@
+(05/05/09)
+*** New configuration property provenance.log which controls whether verbose
+ provenance-related log information is recorded in the run log file or
+ not. By default, this is false, which means that less information is
+ output by default now than previously.
+
(04/27/09)
*** Swift 0.9 built from Swift SVN r2860 and cog SVN r2388
Modified: trunk/docs/userguide.xml
===================================================================
--- trunk/docs/userguide.xml 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/docs/userguide.xml 2009-05-05 16:19:12 UTC (rev 2899)
@@ -2968,6 +2968,23 @@
</para>
</listitem>
</varlistentry>
+
+ <varlistentry>
+ <term>
+ <property>provenance.log</property>
+ </term>
+ <listitem>
+ <para>
+ Valid values: <literal>true</literal>, <literal>false</literal>
+ </para>
+ <para>
+ Default value: <literal>false</literal>
+ </para>
+ <para>
+ This property controls whether the log file will contain provenance information enabling this will increase the size of log files, sometimes significantly.
+ </para>
+ </listitem>
+ </varlistentry>
</variablelist>
Modified: trunk/etc/swift.properties
===================================================================
--- trunk/etc/swift.properties 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/etc/swift.properties 2009-05-05 16:19:12 UTC (rev 2899)
@@ -312,3 +312,10 @@
#
foreach.max.threads=1024
+
+# controls whether the log file will contain provenance information
+# enabling this will increase the size of log files, sometimes
+# significantly.
+
+provenance.log=false
+
Modified: trunk/libexec/vdl.k
===================================================================
--- trunk/libexec/vdl.k 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/libexec/vdl.k 2009-05-05 16:19:12 UTC (rev 2899)
@@ -24,7 +24,11 @@
export(
element(parameterlog, [direction, variable, id],
- log("info","PARAM thread={#thread} direction={direction} variable={variable} provenanceid={id}")
+
+ if(
+ vdl:configProperty("provenance.log") == "true"
+ log("info","PARAM thread={#thread} direction={direction} variable={variable} provenanceid={id}")
+ )
)
element(split, [var], each(str:split(vdl:getFieldValue(var), " ")))
Modified: trunk/src/org/griphyn/vdl/mapping/AbstractDataNode.java
===================================================================
--- trunk/src/org/griphyn/vdl/mapping/AbstractDataNode.java 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/src/org/griphyn/vdl/mapping/AbstractDataNode.java 2009-05-05 16:19:12 UTC (rev 2899)
@@ -20,6 +20,9 @@
import org.griphyn.vdl.karajan.VDL2FutureException;
+import org.griphyn.vdl.util.VDL2Config;
+
+
public abstract class AbstractDataNode implements DSHandle {
static final String DATASET_URI_PREFIX = "tag:benc at ci.uchicago.edu,2008:swift:dataset:";
@@ -392,12 +395,15 @@
notifyListeners();
logger.info("closed " + this.getIdentifyingString());
// so because its closed, we can dump the contents
+
try {
- logContent();
+ if(VDL2Config.getConfig().getProvenanceLog()) {
+ logContent();
+ }
}
catch (Exception e) {
logger.warn("Exception whilst logging dataset content for " + this,
- e);
+ e);
}
// TODO record retrospective provenance information for this dataset
// here
Modified: trunk/src/org/griphyn/vdl/util/VDL2Config.java
===================================================================
--- trunk/src/org/griphyn/vdl/util/VDL2Config.java 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/src/org/griphyn/vdl/util/VDL2Config.java 2009-05-05 16:19:12 UTC (rev 2899)
@@ -83,6 +83,7 @@
put("throttle.file.operations", "8");
put("throttle.score.job.factor", "4");
put(VDL2ConfigProperties.SITEDIR_KEEP, "false");
+ put(VDL2ConfigProperties.PROVENANCE_LOG, "false");
put("replication.enabled", "false");
put("replication.min.queue.time", "60");
@@ -202,6 +203,10 @@
return Boolean.valueOf(getProperty(VDL2ConfigProperties.SITEDIR_KEEP, "true")).booleanValue();
}
+ public boolean getProvenanceLog() {
+ return Boolean.valueOf(getProperty(VDL2ConfigProperties.PROVENANCE_LOG, "false")).booleanValue();
+ }
+
public String toString() {
return "Swift configuration " + files;
}
Modified: trunk/src/org/griphyn/vdl/util/VDL2ConfigProperties.java
===================================================================
--- trunk/src/org/griphyn/vdl/util/VDL2ConfigProperties.java 2009-05-05 15:31:26 UTC (rev 2898)
+++ trunk/src/org/griphyn/vdl/util/VDL2ConfigProperties.java 2009-05-05 16:19:12 UTC (rev 2899)
@@ -24,6 +24,7 @@
public static final String KICKSTART_ALWAYS_TRANSFER = "kickstart.always.transfer";
public static final String WRAPPERLOG_ALWAYS_TRANSFER = "wrapperlog.always.transfer";
public static final String SITEDIR_KEEP = "sitedir.keep";
+ public static final String PROVENANCE_LOG = "provenance.log";
public static final Map PROPERTIES;
static {
@@ -109,6 +110,12 @@
"If set to true, keeps remote site run directory after execution has completed."));
+ PROPERTIES.put(
+ PROVENANCE_LOG,
+ new PropInfo(
+ "<true|false>",
+ "If set to true, will record provenance information in the log file"));
+
}
public static Map getPropertyDescriptions() {
More information about the Swift-commit
mailing list