9687: Added exit_code method to work_unit interface declarations. Simplified state_la...
[arvados.git] / apps / workbench / app / models / work_unit.rb
index 8da6d92f4abd692c21c168f165df87b37ebd6c1a..ce55bb3c176df2ef3ef32c36bda8898da9dabb0c 100644 (file)
@@ -17,10 +17,18 @@ class WorkUnit
     # returns uuid of the user who modified this work unit most recently
   end
 
+  def owner_uuid
+    # returns uuid of the owner of this work unit
+  end
+
   def created_at
     # returns created_at timestamp
   end
 
+  def modified_at
+    # returns modified_at timestamp
+  end
+
   def started_at
     # returns started_at timestamp for this work unit
   end
@@ -33,6 +41,10 @@ class WorkUnit
     # returns a string representing state of the work unit
   end
 
+  def exit_code
+    # returns the work unit's execution exit code
+  end
+
   def state_bootstrap_class
     # returns a class like "danger", "success", or "warning" that a view can use directly to make a display class
   end
@@ -87,8 +99,8 @@ class WorkUnit
     # returns if this is nondeterministic
   end
 
-  def output
-    # returns uuid or pdh of output data, if any
+  def outputs
+    # returns array containing uuid or pdh of output data
   end
 
   def child_summary
@@ -151,4 +163,40 @@ class WorkUnit
   def is_failed?
     # is this work unit in failed state?
   end
+
+  def command
+    # command to execute
+  end
+
+  def cwd
+    # initial workind directory
+  end
+
+  def environment
+    # environment variables
+  end
+
+  def mounts
+    # mounts
+  end
+
+  def output_path
+    # path to a directory or file to save output
+  end
+
+  def container_uuid
+    # container_uuid of a container_request
+  end
+
+  def log_object_uuids
+    # object uuids for live log
+  end
+
+  def live_log_lines(limit)
+    # fetch log entries from logs table for @proxied
+  end
+
+  def render_log
+    # return partial and locals to be rendered
+  end
 end