The + means we should concatenate everything in the directory. Do that.
This was totally broken before (and unused until now).
Signed-off-by: Sage Weil <sage@inktank.com>
Use --limit to limit the number of jobs being scheduled during
teuthology-suite. Also can be used with schedule_suite.sh via the
10th argument.
Signed-off-by: Sandon Van Ness <sandon@inktank.com>
Signed-off-by: Yuri Weinstein <yuri.weinstein@inktank.com>
The original attempt to fix this with dda7954090
failed because I screwed up the indentation for the out.append(...) line.
Signed-off-by: Sage Weil <sage@inktank.com>
This fixes a bug where a directory with just % generates a
bogus job item with no actual content. (e.g.,
$ find basic
basic
basic/%
$ teuthology-suite --dry-run --base . --collections basic --name foo
INFO:teuthology.suite:Collection basic in ./basic
INFO:teuthology.suite:configs [('basic/{}', [])]
...which then blows up because the job yaml is empty. With
the fix, there are no generated jobs:
$ teuthology-suite --dry-run --base . --collections basic --name foo
INFO:teuthology.suite:Collection basic in ./basic
INFO:teuthology.suite:configs []
(The configs print was temporarily added for debugging
purposes.)
Signed-off-by: Sage Weil <sage@inktank.com>
Previous, a collection was a directory like this:
mycollection/
mycollection/facet1/
mycollection/facet1/1a.yaml
mycollection/facet1/1b.yaml
mycollection/facet2/
mycollection/facet2/2a.yaml
mycollection/facet3/
mycollection/facet3/3a.yaml
mycollection/facet3/3b.yaml
and this would expand to
1a + 2a + 3a
1a + 2a + 3b
1b + 2a + 3a
1b + 2a + 3b
The fixed directory depth and requirement for a subdir even
when there is only 1 item is annoying. Instead, allow an
arbitrary directory structure, with the following rules:
- a .yaml file is a taken as-is (duh); other files still
ignored
- a directory is normally just a way to organize files. We
recursively descend and build a list of what we fine.
- a directory with a '%' file in it is special:
- take the product of every item in the dir (much like
we did before)
- a directory with a '+' file in it is special:
- concatenate everything in the dir into one job
Note that this is equivalent to the previous structure if we
do:
for facet in mycollection/* ; do touch $facet/% ; done
We can clean up slightly be taking any dir with only one yaml
file in it and replacing the dir with the bare .yaml.
Once this is done, we can reorganize directories however we
like.
Signed-off-by: Sage Weil <sage@inktank.com>