[ARVADOS] updated: d1e378c28ab57bd0d68a09343e84628202c404cc

git at public.curoverse.com git at public.curoverse.com
Tue Mar 4 11:49:00 EST 2014


Summary of changes:
 apps/admin/setup-new-user.rb                       |    6 ++--
 .../app/assets/stylesheets/application.css.scss    |    2 +-
 .../app/controllers/keep_disks_controller.rb       |    5 ++++
 .../controllers/pipeline_instances_controller.rb   |    2 +-
 apps/workbench/app/helpers/application_helper.rb   |    7 ++++-
 doc/_config.yml                                    |    2 +-
 doc/_includes/_navbar_top.liquid                   |   10 ++++----
 doc/install/install-api-server.html.md.liquid      |   12 +++++----
 .../install-crunch-dispatch.html.textile.liquid    |    8 ++++++
 doc/sdk/python/sdk-python.html.textile.liquid      |    2 +-
 .../check-environment.html.textile.liquid          |    6 ++--
 doc/user/reference/api-tokens.html.textile.liquid  |    2 +-
 doc/user/reference/sdk-cli.html.textile.liquid     |    2 +-
 .../running-external-program.html.textile.liquid   |    2 +-
 .../tutorial-firstscript.html.textile.liquid       |    2 +-
 ...rial-gatk-variantfiltration.html.textile.liquid |    2 +-
 .../tutorial-job-debug.html.textile.liquid         |    2 +-
 .../tutorials/tutorial-job1.html.textile.liquid    |    2 +-
 .../tutorials/tutorial-keep.html.textile.liquid    |    2 +-
 .../tutorial-new-pipeline.html.textile.liquid      |    4 +-
 .../tutorial-parallel.html.textile.liquid          |    2 +-
 .../tutorial-trait-search.html.textile.liquid      |    2 +-
 sdk/cli/bin/crunch-job                             |   26 ++++++++++---------
 sdk/python/arvados/fuse.py                         |    1 -
 sdk/python/bin/arv-mount                           |    3 +-
 sdk/ruby/Gemfile.lock                              |    8 +++---
 .../app/controllers/arvados/v1/jobs_controller.rb  |    1 +
 services/api/app/models/pipeline_instance.rb       |    4 +++
 services/api/script/crunch-dispatch.rb             |   15 +++++++++++
 .../api/test/integration/collections_api_test.rb   |    4 ---
 services/api/test/integration/jobs_api_test.rb     |   23 +++++++++++++++++
 services/api/test/test_helper.rb                   |    6 ++++
 32 files changed, 121 insertions(+), 56 deletions(-)
 create mode 100644 services/api/test/integration/jobs_api_test.rb

       via  d1e378c28ab57bd0d68a09343e84628202c404cc (commit)
       via  41c7c826a7e4c3a074a6ab5a719bf4c88e9a0e28 (commit)
       via  9c3dd1f301b78d556b9d06c81a01c4b4446803ff (commit)
       via  6c2b15626cff7c94b0727ab6f3eac7dfde56b6ed (commit)
       via  e60990e8ccc42495fb8ec1afe53bb47b1b604866 (commit)
       via  2bf9aeb2508a6f61518bf838390e31e07e9fe0e1 (commit)
       via  d1b3c09b51e11a26ac7e735805b79fa4668bbaff (commit)
       via  94eca7452812a90d68dd29dc62fe2ac5c5157568 (commit)
       via  9a124cfd453548bb447df9513f72809a1fba0433 (commit)
       via  f96533820a514a36c618c8343d4b6320c7c31cf6 (commit)
       via  2abf7fca110acf699645f45025b62608d287bdd4 (commit)
       via  06362e4d206c4765567e0a6b5585197ce0c9d30f (commit)
       via  342f1555625580dc945766a48bb7be3625af2deb (commit)
       via  4f6d03f8329ec63704f6830c56b95be939b38d30 (commit)
       via  1b8615efd89707d02ea9de1d95e9e2a26b0436cc (commit)
      from  ac5a69c5c0aaf0786023caa4599a6c55d67310bc (commit)

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 d1e378c28ab57bd0d68a09343e84628202c404cc
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Tue Mar 4 11:50:19 2014 -0500

    Working on having crunch-dispatch manage pipelines.

diff --git a/apps/workbench/app/controllers/keep_disks_controller.rb b/apps/workbench/app/controllers/keep_disks_controller.rb
index 482a2d3..cc89228 100644
--- a/apps/workbench/app/controllers/keep_disks_controller.rb
+++ b/apps/workbench/app/controllers/keep_disks_controller.rb
@@ -1,2 +1,7 @@
 class KeepDisksController < ApplicationController
+  def create
+    defaults = { is_readable: true, is_writable: true }
+    @object = KeepDisk.new defaults.merge(params[:keep_disk] || {})
+    super
+  end
 end
diff --git a/apps/workbench/app/controllers/pipeline_instances_controller.rb b/apps/workbench/app/controllers/pipeline_instances_controller.rb
index b477223..8374628 100644
--- a/apps/workbench/app/controllers/pipeline_instances_controller.rb
+++ b/apps/workbench/app/controllers/pipeline_instances_controller.rb
@@ -59,7 +59,7 @@ class PipelineInstancesController < ApplicationController
                   pipeline[component_name][:script_parameters][param_name] = param_value[:value]
                 elsif param_value[:default]
                   pipeline[component_name][:script_parameters][param_name] = param_value[:default]
-                elsif param_value[:optional] != nil or param_value[:required] != nil
+                elsif param_value[:optional] != nil or param_value[:required] != nil or param_value[:dataclass] != nil
                     pipeline[component_name][:script_parameters][param_name] = ""
                 else
                   pipeline[component_name][:script_parameters][param_name] = param_value
diff --git a/apps/workbench/app/helpers/application_helper.rb b/apps/workbench/app/helpers/application_helper.rb
index 6de96e8..01569eb 100644
--- a/apps/workbench/app/helpers/application_helper.rb
+++ b/apps/workbench/app/helpers/application_helper.rb
@@ -137,7 +137,12 @@ module ApplicationHelper
 
     return attrvalue if !object.attribute_editable? attr
 
-    if not dataclass
+    if dataclass
+      begin
+        dataclass = dataclass.constantize
+      rescue NameError
+      end
+    else
       rsc = template
       if template.is_a? Hash
         if template[:value]
diff --git a/services/api/app/models/pipeline_instance.rb b/services/api/app/models/pipeline_instance.rb
index 43497da..ad96b77 100644
--- a/services/api/app/models/pipeline_instance.rb
+++ b/services/api/app/models/pipeline_instance.rb
@@ -61,6 +61,10 @@ class PipelineInstance < ArvadosModel
     t.collect { |r| r[2] }.inject(0.0) { |sum,a| sum += a } / t.size
   end
 
+  def self.queue
+    self.where('active = true')
+  end
+
   protected
   def bootstrap_components
     if pipeline_template and (!components or components.empty?)
diff --git a/services/api/script/crunch-dispatch.rb b/services/api/script/crunch-dispatch.rb
index 59ea162..3b2d5ba 100755
--- a/services/api/script/crunch-dispatch.rb
+++ b/services/api/script/crunch-dispatch.rb
@@ -38,6 +38,7 @@ class Dispatcher
 
   def refresh_todo
     @todo = Job.queue
+    @todo_pipelines = PipelineInstance.queue
   end
 
   def sinfo
@@ -313,6 +314,15 @@ class Dispatcher
     @running.delete job_done.uuid
   end
 
+  def update_pipelines
+    puts @todo_pipelines
+    @todo_pipelines.each do |p|
+      puts "arv-run-pipeline-instance --no-wait --instance #{p.uuid}"
+      puts `env`
+      `arv-run-pipeline-instance --no-wait --instance #{p.uuid}`
+    end
+  end
+
   def run
     act_as_system_user
     @running ||= {}
@@ -337,6 +347,9 @@ class Dispatcher
         unless @todo.empty? or did_recently(:start_jobs, 1.0) or $signal[:term]
           start_jobs
         end
+        unless @todo_pipelines.empty? or did_recently(:update_pipelines, 5.0)
+          update_pipelines
+        end
       end
       reap_children
       select(@running.values.collect { |j| [j[:stdout], j[:stderr]] }.flatten,
@@ -344,6 +357,8 @@ class Dispatcher
     end
   end
 
+
+
   protected
 
   def did_recently(thing, min_interval)

commit 41c7c826a7e4c3a074a6ab5a719bf4c88e9a0e28
Merge: ac5a69c 9c3dd1f
Author: Peter Amstutz <peter.amstutz at curoverse.com>
Date:   Tue Mar 4 10:52:00 2014 -0500

    Merge remote-tracking branch 'origin/master' into 2049-run-job-from-workbench


-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list