Variable severity penalty on same constraint #706
Replies: 1 comment 2 replies
-
Hello @mikepictor - I see your point. Unfortunately, this is currently not possible - your workaround with multiple constraints is the only way how I could see it done. To that end, we've actually implemented (and will soon release) a feature for our Enterprise customers that can actually merge these constraints, doing the work only once. The feature is called "automatic node sharing" if you want to look it up later. And it is actually useful for more situations than this, as it can reuse even parts of the work done by multiple constraints. There are possible ways how I could see the Constraint Streams API changing to allow for your use case, but in the interest of openness, I don't think we'll be working on it in the foreseeable future. |
Beta Was this translation helpful? Give feedback.
-
Is it possible, in one constraint, to produce variable severities? What I want is a date comparison, where exact date match is ideal, but if date 1 is before date 2, that is a soft penalty, but if date 2 is before date 1 that is a hard penalty
So something along these lines
I can obviously do this in 2 different constraints, but I am checking the exact same entities and properties in both cases, so I am hoping to avoid the performance overhead of evaluating 2 different constraints
Beta Was this translation helpful? Give feedback.
All reactions