Allow job handlers to be exempted from the default random choice pool.

This commit is contained in:
Nate Coraor
2012-03-31 10:06:43 -04:00
parent 9894c0bd9a
commit 279ef87834
3 changed files with 9 additions and 1 deletions
+1
View File
@@ -193,6 +193,7 @@ class Configuration( object ):
# Store advanced job management config
self.job_manager = kwargs.get('job_manager', self.server_name).strip()
self.job_handlers = [ x.strip() for x in kwargs.get('job_handlers', self.server_name).split(',') ]
self.default_job_handlers = [ x.strip() for x in kwargs.get('default_job_handlers', ','.join( self.job_handlers ) ).split(',') ]
# Use database for IPC unless this is a standalone server (or multiple servers doing self dispatching in memory)
self.track_jobs_in_database = True
if ( len( self.job_handlers ) == 1 ) and ( self.job_handlers[0] == self.server_name ) and ( self.job_manager == self.server_name ):
+1 -1
View File
@@ -791,7 +791,7 @@ class Tool:
self.parallelism = None
# Set job handler(s). Each handler is a dict with 'url' and, optionally, 'params'.
self_id = self.id.lower()
self.job_handlers = [ { "name" : name } for name in self.app.config.job_handlers ]
self.job_handlers = [ { "name" : name } for name in self.app.config.default_job_handlers ]
# Set custom handler(s) if they're defined.
if self_id in self.app.config.tool_handlers:
self.job_handlers = self.app.config.tool_handlers[ self_id ]
+7
View File
@@ -562,6 +562,13 @@ use_interactive = True
# comma-separated list.
#job_handlers = main
# By default, a handler from job_handlers will be selected at random if the
# tool to run does specify a handler below in [galaxy:tool_handlers]. If you
# want certain handlers to only handle jobs for tools/params explicitly
# assigned below, use default_job_handlers to specify which handlers should be
# used for jobs without explicit handlers.
#default_job_handlers = main
# This enables splitting of jobs into tasks, if specified by the particular tool config.
# This is a new feature and not recommended for production servers yet.
#use_tasked_jobs = False