fix next-pool overrides by job#2279
Merged
BareosBot merged 4 commits intobareos:masterfrom Sep 2, 2025
Merged
Conversation
Contributor
Author
|
The code is still awkward because the ScanCommandLineArguments method in ua_run.cc also sets values that are not given in the command line, applying overrides. |
Contributor
Author
|
Also, is the name of the method ResetRestoreContext in ua_run.cc correct? The method updates jcr->dir_impl->res values from a RunContext reference, no RestoreContext at all. |
1c2657f to
604e379
Compare
sebsura
requested changes
Jun 4, 2025
Contributor
sebsura
left a comment
There was a problem hiding this comment.
I have not tested this manually yet. Could you add a test that tests the overrides ?
We probably already have a suite that uses copy jobs, so feel free to add one testrunner each for the two cases.
7ef3de2 to
4f109e7
Compare
sebsura
approved these changes
Aug 28, 2025
Contributor
sebsura
left a comment
There was a problem hiding this comment.
Looks good to me. Thanks for the work!
Fixes bareos#2253: Copy job fails, because "Next Pool" is not accepted as an override in the job config.
db9cdcf to
46ebdb4
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The next pool directive can be defined in the Pool and Job resource, the next pool directive in the Job resource should override the directive in the Pool resource. Currently, The directive in the job resource is not taken into account when running a job via the "run" command in the bconsole. This PR fixes this and takes the directive from the Job resource if specified.
Also, this PR adds a section in the copy-migrate systemtest to test the override behaviour of this directive.
Fixes #2253: Copy job fails, because "Next Pool" is not accepted as an override in the job config.
Thank you for contributing to the Bareos Project!
Please check
If you have any questions or problems, please give a comment in the PR.
Helpful documentation and best practices
Checklist for the reviewer of the PR (will be processed by the Bareos team)
Make sure you check/merge the PR using
devtools/pr-toolto have some simple automated checks run and a proper changelog record added.General
Required backport PRs have been createdSource code quality
Tests