Skip to content

Commit

Permalink
mxqd_control: Check prerequisites against empty group tags
Browse files Browse the repository at this point in the history
We want to be able to use group tags as a stigma so that servers can be
configured to accept only jobs without certain tags. For example,
mxqi can add a tag "mxqi" to its jobs and the servers which shouldn't
run mxqi jobs can use "!mxqi" as their prerequisites.

However, for that to work, we need to evaluate server prerequistes even
for jobs which don't have any tags.

Remove the check, which skips server prerequistes evaluation for jobs
without tags.
  • Loading branch information
donald committed Jun 2, 2024
1 parent f6a8a42 commit 7c3e220
Showing 1 changed file with 0 additions and 3 deletions.
3 changes: 0 additions & 3 deletions mxqd_control.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,9 +35,6 @@ static int server_is_qualified(struct mxq_server *server, struct mxq_group *grou
return 0; // evaluated to false
}
if (*server->daemon.prerequisites != 0) {
if (*group->tags == 0) {
return 0;
}
_mx_cleanup_(keywordset_free_byref) struct keywordset *kws = keywordset_new(group->tags);
struct parser_context parser_context = {
.input = server->daemon.prerequisites,
Expand Down

0 comments on commit 7c3e220

Please sign in to comment.