[ARVADOS] updated: 612d5fd9a0066665b522997f025499460d9edf43
git at public.curoverse.com
git at public.curoverse.com
Sat Aug 9 17:15:47 EDT 2014
Summary of changes:
sdk/cli/bin/arv-run-pipeline-instance | 15 ++++++++-------
1 file changed, 8 insertions(+), 7 deletions(-)
discards 898af1ecdd211f8e03bf271af8bf8f56f7cee167 (commit)
via 612d5fd9a0066665b522997f025499460d9edf43 (commit)
This update added new revisions after undoing existing revisions. That is
to say, the old revision is not a strict subset of the new revision. This
situation occurs when you --force push a change and generate a repository
containing something like this:
* -- * -- B -- O -- O -- O (898af1ecdd211f8e03bf271af8bf8f56f7cee167)
\
N -- N -- N (612d5fd9a0066665b522997f025499460d9edf43)
When this happens we assume that you've already had alert emails for all
of the O revisions, and so we here report only the revisions in the N
branch from the common base, B.
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
commit 612d5fd9a0066665b522997f025499460d9edf43
Author: Tom Clegg <tom at curoverse.com>
Date: Sat Aug 9 17:15:43 2014 -0400
3212: Support arv-run-pipeline-instance --no-reuse --submit
diff --git a/sdk/cli/bin/arv-run-pipeline-instance b/sdk/cli/bin/arv-run-pipeline-instance
index 389ce9c..265d634 100755
--- a/sdk/cli/bin/arv-run-pipeline-instance
+++ b/sdk/cli/bin/arv-run-pipeline-instance
@@ -454,16 +454,28 @@ class WhRunPipelineInstance
end
def setup_instance
- if $options[:submit]
- @instance ||= PipelineInstance.
- create(:components => @components,
- :pipeline_template_uuid => @template[:uuid],
- :state => 'New')
+ if @instance
+ @instance[:properties][:run_options] ||= {}
+ if @options[:no_reuse]
+ # override properties of existing instance
+ @instance[:properties][:run_options][:enable_job_reuse] = false
+ else
+ # Default to "enable reuse" if not specified. (This code path
+ # can go away when old clients go away.)
+ if @instance[:properties][:run_options][:enable_job_reuse].nil?
+ @instance[:properties][:run_options][:enable_job_reuse] = true
+ end
+ end
else
- @instance ||= PipelineInstance.
- create(:components => @components,
- :pipeline_template_uuid => @template[:uuid],
- :state => 'RunningOnClient')
+ @instance = PipelineInstance.
+ create(components: @components,
+ properties: {
+ run_options: {
+ enable_job_reuse: !@options[:no_reuse]
+ }
+ },
+ pipeline_template_uuid: @template[:uuid],
+ state: ($options[:submit] ? 'New' : 'RunningOnClient'))
end
self
end
@@ -503,7 +515,8 @@ class WhRunPipelineInstance
# dealing with new API servers.
:minimum_script_version => c[:minimum_script_version],
:exclude_script_versions => c[:exclude_minimum_script_versions],
- :find_or_create => !(@options[:no_reuse] || c[:nondeterministic]),
+ :find_or_create => (@instance[:properties][:run_options].andand[:enable_job_reuse] &&
+ !c[:nondeterministic]),
:filters => c[:filters]
})
if job
-----------------------------------------------------------------------
hooks/post-receive
--
More information about the arvados-commits
mailing list