[KULRICE-5400] Case/When statement does not execute RequiredConstraint (SimpleConstraint) DictionaryValidatoinServiceImpl Created: 19/Jul/11  Updated: 23/Feb/12  Resolved: 31/Jul/11

Status: Closed
Project: Kuali Rice Development
Component/s: Data Dictionary
Affects Version/s: 2.0.0-m5
Fix Version/s: 2.0.0-m7, 2.0
Security Level: Public (Public: Anyone can view)

Type: Bug Fix Priority: Major
Reporter: Norm Wright Assignee: Will Gomes (Inactive)
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
cloned to KULRICE-5439 Dictionary Validation Service does no... Open
cloned to KULRICE-5454 Don't validate sub-fields if the fiel... Closed
cloned to KULRICE-5553 Case/When not implemented properly Closed
Similar issues:
KULRICE-5553Case/When not implemented properly
KULRICE-7699AttributeDefinition is missing SimpleConstraint
KULRICE-8916Improve SimpleConstraint to support both inclusive and exclusive min/max
KULRICE-12344Issue with IdentityArchiveServiceImpl when entity does not have principal
KULRICE-12708States are not taken into account when required indicator is set
KULRICE-3045User lookup workaround for case when name field is not rendered
KULRICE-12414Responsibility actions are not saved in all cases when editing roles
KULRICE-6411Character Encoding Statement Needed
KULRICE-1296Add an ordering component to the unit test annotations for statements and files
KULRICE-4524Manual execution of createproject.groovy for 1.0.3
Rice Module:
Application Requirement:
KAI Review Status: Not Required
KTI Review Status: Not Required


Created a case/when constraint that is supposed to add a RequiredConstraint (really a SimpleConstraint) to be executed but the RequiredConstraint never gets executed.

Running the debugger the case/when executes properly and the RequiredConstraint (actually a SimpleConstraint with required=true) successfully gets added to the list of additionalConstraints and then added to the constraintQueue but it does not get executed by the ExistenceConstraintProcessor.java

I think it is in this piece of code in the DictionaryValidationServiceImpl.java.
// If this constraint is not one that this process handles, then skip and add to the queue for the next processor;
// obviously this would be redundant (we're only looking at constraints that this processor can process) except that
// the previous processor might have stuck a new constraint (or constraints) on the queue
if (!constraintType.isInstance(constraint))

{ result.addSkipped(attributeValueReader, processor.getName()); additionalConstraints.add(constraint); continue; }

I think it is because in the debugger the constraintType is ExistenceConstraint.class but SimpleConstraint.java does not implement ExistenceConstraint.java

Comment by Norm Wright [ 27/Jul/11 ]

A test that shows this error can be found in


Comment by Rice-CI User (Inactive) [ 01/Aug/11 ]

Integrated in rice-trunk-nightly #137 (See http://ci.rice.kuali.org/job/rice-trunk-nightly/137/)
KULRICE-5400 Implement ExistanceConstraint on SimpleConstraint so it gets processed by constraint processor.

Comment by Jessica Coltrin (Inactive) [ 23/Feb/12 ]

Closing since these items are now in the release notes.

Generated at Sat May 30 00:18:33 CDT 2020 using JIRA 6.1.5#6160-sha1:a61a0fc278117a0da0ec9b89167b8f29b6afdab2.