From 4f4140fbeca6c7dd5202706dd7e8efd25b6f5670 Mon Sep 17 00:00:00 2001 From: gsaudade99 Date: Wed, 29 Jul 2026 16:10:50 +0200 Subject: [PATCH] add htcondor v2 to hanlder 0 --- templates/galaxy/config/job_conf.yml | 13 ++++++++++- templates/galaxy/config/job_conf.yml.j2 | 29 ++++++++++++++++++++++--- 2 files changed, 38 insertions(+), 4 deletions(-) diff --git a/templates/galaxy/config/job_conf.yml b/templates/galaxy/config/job_conf.yml index 8277f8eff..3d877bdec 100644 --- a/templates/galaxy/config/job_conf.yml +++ b/templates/galaxy/config/job_conf.yml @@ -6,15 +6,26 @@ galaxy_jobconf: plugin_workers: 8 handlers: count: "{{ galaxy_systemd_handlers }}" - assign_with: db-skip-locked + assign: db-skip-locked max_grab: 16 ready_window_size: 32 + handler_definitions: + 0: + tags: + - htcondor-apiv2 + plugins: + - htcondor_apiv2 + default_process: + exclude_plugins: + - htcondor_apiv2 plugins: #- id: drmaa #load: galaxy.jobs.runners.drmaa:DRMAAJobRunner #workers: 3 - id: condor load: galaxy.jobs.runners.condor:CondorJobRunner + - id: htcondor_apiv2 + load: galaxy.jobs.runners.htcondor:HTCondorJobRunner - id: local load: galaxy.jobs.runners.local:LocalJobRunner - id: pulsar_embedded diff --git a/templates/galaxy/config/job_conf.yml.j2 b/templates/galaxy/config/job_conf.yml.j2 index 52ad02a9b..bb549259d 100644 --- a/templates/galaxy/config/job_conf.yml.j2 +++ b/templates/galaxy/config/job_conf.yml.j2 @@ -31,9 +31,9 @@ runners: # Job handler configuration # handling: -{% if galaxy_jobconf.handlers.assign_with is defined %} - assign_with: - - {{ galaxy_jobconf.handlers.assign_with }} +{% if galaxy_jobconf.handlers.assign is defined %} + assign: + - {{ galaxy_jobconf.handlers.assign }} {% endif %} {% if galaxy_jobconf.handlers.default is defined %} default: {{ galaxy_jobconf.handlers.default }} @@ -46,8 +46,28 @@ handling: {% endif %} {% if galaxy_systemd_handlers is defined and galaxy_systemd_handlers > 0 %} processes: +{% set handler_definitions = galaxy_jobconf.handlers.handler_definitions | default({}) %} +{% set default_handler_definition = galaxy_jobconf.handlers.default_process | default({}) %} {% for n in range(galaxy_systemd_handlers) %} +{% set handler_definition = handler_definitions.get(n, default_handler_definition) %} {{ galaxy_systemd_handler_prefix }}_{{ n }}: +{% if handler_definition.tags is defined %} + tags: +{% for tag in handler_definition.tags %} + - {{ tag }} +{% endfor %} +{% endif %} +{% if handler_definition.plugins is defined %} + plugins: +{% for plugin in handler_definition.plugins %} + - {{ plugin }} +{% endfor %} +{% elif handler_definition.exclude_plugins is defined %} + plugins: +{% for plugin in galaxy_jobconf.plugins | sort(attribute='id') if plugin.id not in handler_definition.exclude_plugins %} + - {{ plugin.id }} +{% endfor %} +{% endif %} {% endfor %} {% elif galaxy_systemd_handlers is defined and galaxy_systemd_handlers == 0 %} processes: @@ -114,6 +134,9 @@ tools: {% if 'destination' in tool %} environment: {{ tool['destination'] }} {% endif %} +{% if 'handler' in tool %} + handler: {{ tool['handler'] }} +{% endif %} {% if 'resources' in tool %} resources: {{ tool['resources'] }} {% endif %}