srm: Fix saving of transient states to database #2080
Merged
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.
Motivation:
SRM has options of controlling whether job history is stored to the
database as well as whether transient (unimportant) states are
stored.
Yet, the various job storage decorators apply filtering based
on whether job history is enabled. Specifically this means that
if storage of transient states is enabled while job history is
disabled, transient states are not stored.
Modification:
Remove the unnecessary filtering from various job storage implementations.
Renamed FinalStateOnlyJobStorageDecorator to ForceOnlyJobStorageDecorator
since the Scheduler is already forcing save of jobs in final states and
there is no reason to check for final states in the decorator.
Result:
Fixed interpretation of srm.persistence.enable.store-transient-state when
srm.persistence.enable.history is disabled. This may put additional load
on the SRM database if store-transient-state is true and enable.history
is false - the old behaviour can be restored by setting both properties
to false.
Target: trunk
Require-notes: yes
Require-book: no
Request: 2.14
Request: 2.13
Acked-by: Paul Millar paul.millar@desy.de
Patch: https://rb.dcache.org/r/8889/
(cherry picked from commit cadec14)