run -j option fails to find unique job by name
Reported by Greg Schueler | July 12th, 2011 @ 05:29 PM | in Rundeck 1.3 (closed)
the run -j group/name
option fails if multiple jobs
match the specified job name, even if only one job has the exact
job name.
e.g.
Venkman:test greg$ tools/bin/run -j 'test'
# No project specified, defaulting to: test
Error: Failed request to run a job: Job not was not unique: /test: 5 jobs found
when rd-jobs lists only a single job with the exact name "test":
Venkman:test greg$ tools/bin/rd-jobs list
# No project specified, defaulting to: test
# Found 6 jobs:
- asdf
- test - 'test update redirect'
- test2 - 'test update redirect'
- uuidmodify test - 'asdf'
- uuidmodify test2 - 'asdffdd'
- uuidmodify test3 - 'asdf'
workaround: determine id via rd-jobs, and use -i option
fix: the RunDeck API needs to allow exact equality query for job name, and the CLI tool needs to use this query filter
Comments and changes to this ticket
-
Deleted User July 12th, 2011 @ 08:01 PM
- State changed from new to needs_verification
(from [7326a96529bc10deca1acdedf5724f065ab09609]) Add exact job name and group filter parameters for jobs query api, update run tool usage, update tests and docs [#385 state:needs_verification] https://github.com/dtolabs/rundeck/commit/7326a96529bc10deca1acdedf...
-
Alex-SF July 14th, 2011 @ 01:10 PM
This fails as expected...
$ run -j norestest # No project specified, defaulting to: examples Error: Failed request to run a job: Job was not unique: /norestest: 2 jobs found: [2b87983b-a47a-4d77-82a9-8d69cde199f1, 03a50f6b-1570-429c-b337-b8fd051ab0ae]
... given the following jobs ...
$ rd-jobs # No project specified, defaulting to: examples # Found 2 jobs: - norestest - blar/norestest
... but can't seem to run the "norestest" job with new group name
-
Alex-SF July 14th, 2011 @ 01:10 PM
- State changed from needs_verification to open
-
Greg Schueler July 14th, 2011 @ 03:53 PM
- State changed from open to needs_verification
(from [12025c46661686dca5cadd443d0a08f9916cb481]) Update run -j behavior to treat bare job names as in no group [#385 state:needs_verification] https://github.com/dtolabs/rundeck/commit/12025c46661686dca5cadd443...
-
Greg Schueler July 14th, 2011 @ 03:56 PM
updated behavior of -j flag,
-j "job name"
-- this will match a job named "job name" at the top level same thing with-j "/job name"
-
Alex-SF July 15th, 2011 @ 11:06 AM
- State changed from needs_verification to resolved
Verified in http://build.rundeck.org/job/release-1.3-rc/98/
Please Sign in or create a free account to add a new ticket.
With your very own profile, you can contribute to projects, track your activity, watch tickets, receive and update tickets through your email and much more.
Create your profile
Help contribute to this project by taking a few moments to create your personal profile. Create your profile ยป
(DEPRECATED) Please use github issues for issue tracking at http://github.com/dtolabs/rundeck/issues