Procedural Constraints Database Support #1596
Draft
+281
−60
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.
closes #1572
Description
Mirroring the database changes that were made for procedural scheduling support, this PR makes the following changes to the
constraints
sub-schema inmerlin
:invocation_id
was added toconstraint_specification
and made the new (sole) primary key. This allows for multiple "invocations" of that same constraint definition in the same spec.type
enum,uploaded_jar_id
, andparameter
schema fields were added toconstraint_definition
to support procedural constraintsdefinition
was made nullable inconstraint_definition
, since it will be null when that constraint's source code is contained in the uploaded jar.constraint_run
now holds an additional field,constraint_invocation_id
, which replaced(constraint_id, constraint_revision)
in the primary key definition. This is so we can have a constraint run for each invocation in a plan spec, which might share constraint definitions and revisions.constraint_run
also holds the "as run" arguments that were passed to the constraint during execution in a new json fieldarguments
.Verification
WIP
Documentation
Future work