taverna-player 0.8.0 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/.travis.yml +6 -0
- data/CHANGES.rdoc +28 -0
- data/CITATION +20 -0
- data/Gemfile +0 -12
- data/README.rdoc +30 -16
- data/Rakefile +1 -0
- data/app/controllers/taverna_player/workflows_controller.rb +18 -0
- data/app/helpers/taverna_player/application_helper.rb +2 -2
- data/app/models/taverna_player/run.rb +35 -3
- data/app/models/taverna_player/workflow.rb +41 -0
- data/app/views/taverna_player/workflows/_info.json.jbuilder +1 -0
- data/{test/dummy/app/views → app/views/taverna_player}/workflows/index.html.erb +1 -1
- data/app/views/taverna_player/workflows/index.json.jbuilder +1 -0
- data/config/routes.rb +9 -0
- data/db/migrate/20140917165505_create_taverna_player_workflows.rb +12 -0
- data/lib/generators/taverna_player/controllers_generator.rb +5 -6
- data/lib/generators/taverna_player/models_generator.rb +3 -3
- data/lib/generators/templates/callbacks/worker_callbacks.rb +5 -5
- data/{test/dummy/app → lib/generators/templates}/controllers/workflows_controller.rb +7 -4
- data/{test/dummy/test/functional/workflows_controller_test.rb → lib/generators/templates/models/workflow.rb} +6 -7
- data/lib/generators/templates/player_initializer.rb +5 -4
- data/lib/taverna-player.rb +11 -1
- data/lib/taverna_player/concerns/controllers/runs_controller.rb +1 -1
- data/lib/taverna_player/concerns/controllers/workflows_controller.rb +41 -0
- data/lib/taverna_player/concerns/models/run.rb +42 -14
- data/lib/taverna_player/concerns/models/run_port.rb +2 -1
- data/lib/taverna_player/concerns/models/workflow.rb +44 -0
- data/lib/taverna_player/model_proxy.rb +14 -8
- data/lib/taverna_player/version.rb +1 -1
- data/taverna_player.gemspec +1 -0
- data/test/dummy/app/views/layouts/application.html.erb +1 -1
- data/test/dummy/config/initializers/taverna_player.rb +1 -4
- data/test/dummy/config/routes.rb +1 -7
- data/test/dummy/db/migrate/20140917165846_drop_workflows.rb +9 -0
- data/test/dummy/db/migrate/20140917170017_create_taverna_player_workflows.taverna_player.rb +13 -0
- data/test/dummy/db/schema.rb +9 -9
- data/test/dummy/lib/callbacks.rb +4 -4
- data/test/fixtures/delayed_jobs.yml +45 -0
- data/test/fixtures/taverna_player/interactions.yml +3 -3
- data/test/fixtures/taverna_player/run_ports.yml +7 -12
- data/test/fixtures/taverna_player/runs.yml +43 -13
- data/test/fixtures/{workflows.yml → taverna_player/workflows.yml} +1 -4
- data/test/fixtures/users.yml +2 -3
- data/test/functional/taverna_player/runs_controller_test.rb +42 -15
- data/test/functional/taverna_player/workflows_controller_test.rb +37 -0
- data/test/unit/helpers/taverna_player/application_helper_test.rb +1 -1
- data/test/unit/taverna_player/interaction_test.rb +2 -2
- data/test/unit/taverna_player/model_proxy_test.rb +58 -0
- data/test/unit/taverna_player/run_test.rb +103 -23
- data/test/unit/taverna_player/worker_test.rb +2 -0
- metadata +39 -12
- data/test/dummy/app/models/workflow.rb +0 -32
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
MmM4NWJkN2Y1MDc1ZTYzNDc2OTZmZmNlMWRjZjg5ODMzMzUxNjU2Yw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
ZDhhYjNiMDkxMjFhNTA2ZjMzZDFhYTZjNWVhODFmM2JkY2ZjMGFmOA==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
NTdhOTUzZDkxYjVlZmY5MGI0NGM3NDAxZDNjZDI4NTc2NDg0N2NhMjVjMDA0
|
10
|
+
NjFmZjIxYmI5MzYxNDFlNzYwNmNiYTMzYTJkOWIwNjQzNWY4MmI1MzJkMDc0
|
11
|
+
NGVmMjQ1ODZkNzNkNDgyN2IwNDEwODBhZGUzMTA0YjMxODY5ZjU=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
YmMxYTRmNDNjM2ViYjc5MjcwMjE0MWZjODY5ZTBlYmI5Yjk0MzE1MDVmYjRk
|
14
|
+
NzFjMTRjNTdmNzE3NjJjOGFlYjIxYzlkMDQzM2UwZGU0ZjBhMmQxYTNiOWUx
|
15
|
+
MDlhODI4YzVhZTFhNDNhYTJhY2QzZGI2Y2IxNGZjZjA5OGZiYWI=
|
data/.travis.yml
CHANGED
data/CHANGES.rdoc
CHANGED
@@ -1,5 +1,33 @@
|
|
1
1
|
= Changes log for Taverna Player
|
2
2
|
|
3
|
+
== Version 0.9.0
|
4
|
+
|
5
|
+
* Add a test to check if a Run's delayed_job has failed.
|
6
|
+
* Destroy failed delayed_jobs when destroying Runs.
|
7
|
+
* Add a CITATION file.
|
8
|
+
* Test cancelling a Run before it starts running.
|
9
|
+
* Add Run#pending?
|
10
|
+
* Add Run#initialized?
|
11
|
+
* Add Run#incomplete?
|
12
|
+
* Allow cancelling a run if its delayed_job fails.
|
13
|
+
* Add a test for Run#initialized?
|
14
|
+
* Use the latest t2flow gem for the tests.
|
15
|
+
* Add a default Workflow model.
|
16
|
+
* Fix up the user proxy for tests vs the dev app.
|
17
|
+
* Update the installer templates.
|
18
|
+
* Refactor ModelProxy so constantization is delayed.
|
19
|
+
* Set the internal Workflow model to be the default.
|
20
|
+
* Only route TavernaPlayer::Workflow if it is in use.
|
21
|
+
* Allow extending of the internal Workflow model.
|
22
|
+
* Allow extending of the internal Workflow controller.
|
23
|
+
* Add the internal Workflow stubs to the generators.
|
24
|
+
* Set the workflow model proxy more simply.
|
25
|
+
* Update the ReadMe with new workflow model infomation.
|
26
|
+
* Ensure the proxied models use a rooted (::) namespace.
|
27
|
+
* Add specific tests for the ModelProxy class.
|
28
|
+
* Output JSON for the workflows controller.
|
29
|
+
* Add a routing test for the workflows controller.
|
30
|
+
|
3
31
|
== Version 0.8.0
|
4
32
|
|
5
33
|
* Add a note about Taverna Server compatibility to the ReadMe.
|
data/CITATION
ADDED
@@ -0,0 +1,20 @@
|
|
1
|
+
To cite Taverna-Player in your publication please use:
|
2
|
+
|
3
|
+
Katherine Wolstencroft, Robert Haines, Donal Fellows, Alan Williams,
|
4
|
+
David Withers, Stuart Owen, Stian Soiland-Reyes, Ian Dunlop,
|
5
|
+
Aleksandra Nenadic, Paul Fisher, Jiten Bhagat, Khalid Belhajjame, Finn Bacall,
|
6
|
+
Alex Hardisty, Abraham Nieva de la Hidalga, Maria P Balcazar Vargas,
|
7
|
+
Shoaib Sufi, Carole Goble. The Taverna workflow suite: designing and
|
8
|
+
executing workflows of Web Services on the desktop, web or in the cloud in
|
9
|
+
Nucleic acids research, 2013, Volume 41, Issue W1, pp W557-W561.
|
10
|
+
|
11
|
+
@article{wolstencroft2013taverna,
|
12
|
+
title={The Taverna workflow suite: designing and executing workflows of Web Services on the desktop, web or in the cloud},
|
13
|
+
author={Wolstencroft, Katherine and Haines, Robert and Fellows, Donal and Williams, Alan and Withers, David and Owen, Stuart and Soiland-Reyes, Stian and Dunlop, Ian and Nenadic, Aleksandra and Fisher, Paul and others},
|
14
|
+
journal={Nucleic acids research},
|
15
|
+
volume={41},
|
16
|
+
number={W1},
|
17
|
+
pages={W557--W561},
|
18
|
+
year={2013},
|
19
|
+
publisher={Oxford University Press}
|
20
|
+
}
|
data/Gemfile
CHANGED
@@ -1,18 +1,6 @@
|
|
1
1
|
source "https://rubygems.org"
|
2
2
|
|
3
|
-
# Declare your gem's dependencies in taverna_player.gemspec.
|
4
|
-
# Bundler will treat runtime dependencies like base dependencies, and
|
5
|
-
# development dependencies will be added by default to the :development group.
|
6
3
|
gemspec
|
7
4
|
|
8
5
|
# These gems are used by the dummy application
|
9
6
|
gem "jquery-rails"
|
10
|
-
gem "taverna-t2flow", "~> 0.4.5"
|
11
|
-
|
12
|
-
# Declare any dependencies that are still in development here instead of in
|
13
|
-
# your gemspec. These might include edge Rails or gems from your path or
|
14
|
-
# Git. Remember to move these dependencies to your gemspec before releasing
|
15
|
-
# your gem to rubygems.org.
|
16
|
-
|
17
|
-
# To use debugger
|
18
|
-
# gem 'debugger'
|
data/README.rdoc
CHANGED
@@ -7,7 +7,7 @@ Licence:: BSD (See LICENCE or http://www.opensource.org/licenses/bsd-license
|
|
7
7
|
Copyright:: (c) 2013, 2014 The University of Manchester, UK
|
8
8
|
|
9
9
|
{<img src="https://badge.fury.io/rb/taverna-player.svg" alt="Gem Version" />}[http://badge.fury.io/rb/taverna-player]
|
10
|
-
{<img src="https://codeclimate.com/github/myGrid/taverna-player.
|
10
|
+
{<img src="https://codeclimate.com/github/myGrid/taverna-player/badges/gpa.svg" />}[https://codeclimate.com/github/myGrid/taverna-player]
|
11
11
|
{<img src="https://travis-ci.org/myGrid/taverna-player.svg?branch=master" alt="Build Status" />}[https://travis-ci.org/myGrid/taverna-player]
|
12
12
|
{<img src="https://coveralls.io/repos/myGrid/taverna-player/badge.png?branch=master" alt="Coverage Status" />}[https://coveralls.io/r/myGrid/taverna-player?branch=master]
|
13
13
|
|
@@ -22,9 +22,8 @@ Taverna Player handles all aspects of running a workflow including:
|
|
22
22
|
* Presenting workflow interactions to the user
|
23
23
|
* Gathering and download of workflow outputs
|
24
24
|
|
25
|
-
It, purposefully, does not
|
26
|
-
|
27
|
-
* Manage users
|
25
|
+
It, purposefully, does not manage users and its default workflow model is
|
26
|
+
intentionally oversimplified.
|
28
27
|
|
29
28
|
== Prerequisites
|
30
29
|
|
@@ -109,9 +108,10 @@ Mount the Taverna Player engine in your <tt>config/routes.rb</tt>. For example:
|
|
109
108
|
|
110
109
|
mount TavernaPlayer::Engine, :at => "/"
|
111
110
|
|
112
|
-
Taverna Player provides
|
111
|
+
Taverna Player provides four resources with paths:
|
113
112
|
|
114
113
|
* <tt>/runs/*</tt>
|
114
|
+
* <tt>/workflows/*</tt>
|
115
115
|
* <tt>/service_credentials/*</tt>
|
116
116
|
* <tt>/job_queue</tt>
|
117
117
|
|
@@ -129,11 +129,18 @@ set (for example):
|
|
129
129
|
And the resource paths would become:
|
130
130
|
|
131
131
|
* <tt>/runs/*</tt>
|
132
|
+
* <tt>/workflows/*</tt>
|
132
133
|
* <tt>/admin/service_credentials/*</tt>
|
133
134
|
* <tt>/admin/job_queue</tt>
|
134
135
|
|
135
|
-
|
136
|
-
|
136
|
+
The supplied workflow model also nests the run resources within it:
|
137
|
+
|
138
|
+
* <tt>/workflows</tt>
|
139
|
+
* <tt>/workflows/{workflow-id}/runs/*</tt>
|
140
|
+
|
141
|
+
If you override the default workflow model (see below for details) you can
|
142
|
+
also nest the Taverna Player runs resources within your workflows resources if
|
143
|
+
you wish, like this (within your application's <tt>config/routes.rb</tt>):
|
137
144
|
|
138
145
|
resources :workflows do
|
139
146
|
resources :runs, :controller => "TavernaPlayer::Runs", :except => :edit
|
@@ -198,13 +205,13 @@ so that they take precedence over the default ones. You can delete any that you
|
|
198
205
|
do not need to customize but there are no penalties for leaving them there.
|
199
206
|
There is more information on overriding controllers below.
|
200
207
|
|
201
|
-
If you need to override
|
202
|
-
|
208
|
+
If you need to override any Taverna Player models, to add columns to a table
|
209
|
+
for example, you can copy customizable stubs with:
|
203
210
|
|
204
211
|
rails generate taverna_player:models
|
205
212
|
|
206
|
-
The
|
207
|
-
|
213
|
+
The stubs are copied to the <tt>app/models/taverna_player</tt> directory so
|
214
|
+
that they take precedence over the defaults. There is more information on
|
208
215
|
overriding models below.
|
209
216
|
|
210
217
|
If you want to use pre- and post-run callbacks you can setup some basic stubs
|
@@ -229,16 +236,17 @@ information on renderers below.
|
|
229
236
|
== Taverna Player initializers
|
230
237
|
|
231
238
|
Two initializers are installed by the install generator:
|
232
|
-
* {taverna_player.rb}[https://github.com/myGrid/taverna-player/blob/master/lib/generators/templates/player_initializer.rb]:
|
239
|
+
* {config/initializers/taverna_player.rb}[https://github.com/myGrid/taverna-player/blob/master/lib/generators/templates/player_initializer.rb]:
|
233
240
|
This contains configuration of Taverna Player.
|
234
|
-
* {taverna_server.rb.example}[https://github.com/myGrid/taverna-player/blob/master/lib/generators/templates/server_initializer.rb]:
|
241
|
+
* {config/initializers/taverna_server.rb.example}[https://github.com/myGrid/taverna-player/blob/master/lib/generators/templates/server_initializer.rb]:
|
235
242
|
This is used to configure Taverna Player's connection to a Taverna Server.
|
236
243
|
It is initially set up as an example file as you will need to distribute
|
237
244
|
this with your application but you must not check in the contents of the
|
238
245
|
configured version to your repository.
|
239
246
|
|
240
|
-
Both of these files require minimal configuration for simple set ups
|
241
|
-
fully commented with everything that needs to be set - more details
|
247
|
+
Both of these files <b>require minimal configuration</b> for simple set ups
|
248
|
+
and are fully commented with everything that needs to be set - more details
|
249
|
+
below.
|
242
250
|
|
243
251
|
=== Essential (required) configuration
|
244
252
|
|
@@ -252,6 +260,10 @@ called "file_name" then the following will configure this correctly:
|
|
252
260
|
proxy.file_method_name = :file_name
|
253
261
|
end
|
254
262
|
|
263
|
+
Taverna Player has a very simple internal workflow model
|
264
|
+
(TavernaPlayer::Workflow) that you can extend (see below) or replace with the
|
265
|
+
above code.
|
266
|
+
|
255
267
|
Secondly, Taverna Player needs to know where your Taverna Server is and how to
|
256
268
|
authenticate to it:
|
257
269
|
|
@@ -395,7 +407,9 @@ You can override the following core components:
|
|
395
407
|
* RunPort (model)
|
396
408
|
* RunPort::Input (model)
|
397
409
|
* RunPort::Output (model)
|
410
|
+
* Workflow (model)
|
398
411
|
* RunsController
|
412
|
+
* WorkflowController
|
399
413
|
* ServiceCredentialsController
|
400
414
|
* JobQueueController
|
401
415
|
|
@@ -466,7 +480,7 @@ An example callback that just prints out the run's name and workflow id would
|
|
466
480
|
be:
|
467
481
|
|
468
482
|
def player_run_callback(run)
|
469
|
-
w = Workflow.find(run.workflow_id)
|
483
|
+
w = TavernaPlayer::Workflow.find(run.workflow_id)
|
470
484
|
puts "Callback called for run '#{run.name}' of workflow '#{w.id}'"
|
471
485
|
end
|
472
486
|
|
data/Rakefile
CHANGED
@@ -39,6 +39,7 @@ RDoc::Task.new(:rdoc) do |rdoc|
|
|
39
39
|
"app/models/taverna_player/run.rb",
|
40
40
|
"app/models/taverna_player/run_port.rb",
|
41
41
|
"app/models/taverna_player/service_credential.rb",
|
42
|
+
"app/models/taverna_player/workflow.rb",
|
42
43
|
"lib/taverna-player.rb",
|
43
44
|
"lib/taverna_player/port_renderer.rb"
|
44
45
|
]
|
@@ -0,0 +1,18 @@
|
|
1
|
+
#------------------------------------------------------------------------------
|
2
|
+
# Copyright (c) 2013, 2014 The University of Manchester, UK.
|
3
|
+
#
|
4
|
+
# BSD Licenced. See LICENCE.rdoc for details.
|
5
|
+
#
|
6
|
+
# Taverna Player was developed in the BioVeL project, funded by the European
|
7
|
+
# Commission 7th Framework Programme (FP7), through grant agreement
|
8
|
+
# number 283359.
|
9
|
+
#
|
10
|
+
# Author: Robert Haines
|
11
|
+
#------------------------------------------------------------------------------
|
12
|
+
|
13
|
+
module TavernaPlayer
|
14
|
+
class WorkflowsController < TavernaPlayer::ApplicationController
|
15
|
+
# See lib/taverna_player/concerns/controllers/workflows_controller.rb
|
16
|
+
include TavernaPlayer::Concerns::Controllers::WorkflowsController
|
17
|
+
end
|
18
|
+
end
|
@@ -1,5 +1,5 @@
|
|
1
1
|
#------------------------------------------------------------------------------
|
2
|
-
# Copyright (c) 2013 The University of Manchester, UK.
|
2
|
+
# Copyright (c) 2013, 2014 The University of Manchester, UK.
|
3
3
|
#
|
4
4
|
# BSD Licenced. See LICENCE.rdoc for details.
|
5
5
|
#
|
@@ -44,7 +44,7 @@ module TavernaPlayer
|
|
44
44
|
case id_or_model
|
45
45
|
when TavernaPlayer::Run
|
46
46
|
id_or_model.workflow_id
|
47
|
-
when TavernaPlayer.workflow_proxy.
|
47
|
+
when TavernaPlayer.workflow_proxy.class_const
|
48
48
|
id_or_model.id
|
49
49
|
else
|
50
50
|
id_or_model
|
@@ -1,5 +1,5 @@
|
|
1
1
|
#------------------------------------------------------------------------------
|
2
|
-
# Copyright (c) 2013 The University of Manchester, UK.
|
2
|
+
# Copyright (c) 2013, 2014 The University of Manchester, UK.
|
3
3
|
#
|
4
4
|
# BSD Licenced. See LICENCE.rdoc for details.
|
5
5
|
#
|
@@ -36,8 +36,9 @@ module TavernaPlayer
|
|
36
36
|
# :call-seq:
|
37
37
|
# complete? -> boolean
|
38
38
|
#
|
39
|
-
# Is this run complete? If a run is finished or cancelled or failed or
|
40
|
-
# has timed out then it is complete.
|
39
|
+
# Is this run complete? If a run is finished or cancelled or failed or its
|
40
|
+
# underlying worker has failed or it has timed out then it is complete.
|
41
|
+
# #complete? is not quite the direct opposite of #incomplete?
|
41
42
|
|
42
43
|
##
|
43
44
|
# :method: embedded?
|
@@ -76,6 +77,30 @@ module TavernaPlayer
|
|
76
77
|
#
|
77
78
|
# A run will have a parent if it is a child run as part of a sweep.
|
78
79
|
|
80
|
+
##
|
81
|
+
# :method: incomplete?
|
82
|
+
# :call-seq:
|
83
|
+
# incomplete? -> boolean
|
84
|
+
#
|
85
|
+
# Is this run incomplete? If a run is pending or initialized or running
|
86
|
+
# then it is incomplete. #incomplete? is not quite the direct opposite of
|
87
|
+
# #complete?
|
88
|
+
|
89
|
+
##
|
90
|
+
# :method: initialized?
|
91
|
+
# :call-seq:
|
92
|
+
# initialized? -> boolean
|
93
|
+
#
|
94
|
+
# Is this run initialized on Taverna Server but not running yet?
|
95
|
+
|
96
|
+
##
|
97
|
+
# :method: job_failed?
|
98
|
+
# :call-seq:
|
99
|
+
# job_failed? -> boolean
|
100
|
+
#
|
101
|
+
# Did the delayed_job worker running this run fail? This is primarily
|
102
|
+
# intended for internal use only at the moment.
|
103
|
+
|
79
104
|
##
|
80
105
|
# :method: name
|
81
106
|
# :call-seq:
|
@@ -83,6 +108,13 @@ module TavernaPlayer
|
|
83
108
|
#
|
84
109
|
# The name (mnemonic) of this run.
|
85
110
|
|
111
|
+
##
|
112
|
+
# :method: pending?
|
113
|
+
# :call-seq:
|
114
|
+
# pending? -> boolean
|
115
|
+
#
|
116
|
+
# Is this run in the queue?
|
117
|
+
|
86
118
|
##
|
87
119
|
# :method: root_ancestor
|
88
120
|
# :call-seq:
|
@@ -0,0 +1,41 @@
|
|
1
|
+
#------------------------------------------------------------------------------
|
2
|
+
# Copyright (c) 2013, 2014 The University of Manchester, UK.
|
3
|
+
#
|
4
|
+
# BSD Licenced. See LICENCE.rdoc for details.
|
5
|
+
#
|
6
|
+
# Taverna Player was developed in the BioVeL project, funded by the European
|
7
|
+
# Commission 7th Framework Programme (FP7), through grant agreement
|
8
|
+
# number 283359.
|
9
|
+
#
|
10
|
+
# Author: Robert Haines
|
11
|
+
#------------------------------------------------------------------------------
|
12
|
+
|
13
|
+
module TavernaPlayer
|
14
|
+
|
15
|
+
# This class represents a workflow. It is provided as an example model and
|
16
|
+
# can be extended or replaced as required.
|
17
|
+
#
|
18
|
+
# To replace the model completely please read about configuring the workflow
|
19
|
+
# model proxy in the "Taverna Player initializers" section of the ReadMe. To
|
20
|
+
# extend the model please read about "Overriding the default models and
|
21
|
+
# controllers" in the ReadMe.
|
22
|
+
class Workflow < ActiveRecord::Base
|
23
|
+
include TavernaPlayer::Concerns::Models::Workflow
|
24
|
+
|
25
|
+
##
|
26
|
+
# :method: inputs
|
27
|
+
# :call-seq:
|
28
|
+
# inputs -> Hash
|
29
|
+
#
|
30
|
+
# Return a hash of information about this workflow's inputs. The fields
|
31
|
+
# provided are:
|
32
|
+
# * <tt>:name</tt> - The name of the input port.
|
33
|
+
# * <tt>:description</tt> - A textual description (if provided) of the
|
34
|
+
# input port.
|
35
|
+
# * <tt>:example</tt> - Example input data (if provided) for the input
|
36
|
+
# port.
|
37
|
+
#
|
38
|
+
# All data is read directly from the workflow file itself.
|
39
|
+
|
40
|
+
end
|
41
|
+
end
|
@@ -0,0 +1 @@
|
|
1
|
+
json.extract! workflow, :id, :title, :author, :description
|
@@ -0,0 +1 @@
|
|
1
|
+
json.array! @workflows, :partial => "info", :as => :workflow
|
data/config/routes.rb
CHANGED
@@ -11,6 +11,15 @@
|
|
11
11
|
#------------------------------------------------------------------------------
|
12
12
|
|
13
13
|
TavernaPlayer::Engine.routes.draw do
|
14
|
+
|
15
|
+
# Only add the Taverna Player Workflow route if the host app is actually
|
16
|
+
# using it.
|
17
|
+
if TavernaPlayer.workflow_proxy.class_const == TavernaPlayer::Workflow
|
18
|
+
resources :workflows, :only => :index do
|
19
|
+
resources :runs, :controller => :runs, :except => :edit
|
20
|
+
end
|
21
|
+
end
|
22
|
+
|
14
23
|
resources :runs, :except => :edit do
|
15
24
|
member do
|
16
25
|
put "cancel", :action => "cancel"
|
@@ -1,5 +1,5 @@
|
|
1
1
|
#------------------------------------------------------------------------------
|
2
|
-
# Copyright (c) 2013 The University of Manchester, UK.
|
2
|
+
# Copyright (c) 2013, 2014 The University of Manchester, UK.
|
3
3
|
#
|
4
4
|
# BSD Licenced. See LICENCE.rdoc for details.
|
5
5
|
#
|
@@ -19,11 +19,10 @@ module TavernaPlayer
|
|
19
19
|
"customization."
|
20
20
|
|
21
21
|
def copy_controllers
|
22
|
-
|
23
|
-
"
|
24
|
-
|
25
|
-
|
26
|
-
"app/controllers/taverna_player/service_credentials_controller.rb"
|
22
|
+
%w(runs service_credentials workflows).each do |file|
|
23
|
+
copy_file "#{file}_controller.rb",
|
24
|
+
"app/controllers/taverna_player/#{file}_controller.rb"
|
25
|
+
end
|
27
26
|
end
|
28
27
|
end
|
29
28
|
end
|