Uploaded image for project: 'Kuali Rice Development'
  1. Kuali Rice Development
  2. KULRICE-3319

Determine if we need to do some work on the KimTypeService interface to make return types more consistent

    Details

    • Rice Module:
      KIM

      Description

      Ailish sent the following to the Rice dev list in response to a question about the purpose of these different methods, notice her concern on the differences in return types for these:

      validateAttributes: make sure the values are the right size and shape and if there is a reference table that they exist and are active

      validateUniqueAttributes: make sure the principal doesn't have another assignment with the same values for these unique attributes

      validateAttributesAgainstExisting: seems like this is just giving the opportunity to provide a good error for validateUniqueAttributes, given the different return vals and the fact that the example i see in kfs... they are being used in conjunction with one another? location of the method at the end of kim type service base also leads me to believe this was an afterthought, and perhaps refatoring should have been done to make all validate methods return an attribute set instead of a boolean?

      validateUnmodifiableAttributes: make sure the values on the assignment that are considered keys are not changed during an edit... for example for accounting organization hierarchy... chart, org, and doc type cannot change during an edit... but from and to amount and override code can

      fwiw - i worry about the variation in which methods return List<String> vs. AttributeSet vs. boolean here

      not sure if you're looking at kfs code, but the best reference implementations would be there.

        Attachments

          Activity

          ewestfal Eric Westfall created issue -
          ewestfal Eric Westfall made changes -
          Field Original Value New Value
          Description validateAttributes: make sure the values are the right size and shape and if there is a reference table that they exist and are active

          validateUniqueAttributes: make sure the principal doesn't have another assignment with the same values for these unique attributes

           

          validateAttributesAgainstExisting: *seems* like this is just giving the opportunity to provide a good error for validateUniqueAttributes, given the different return vals and the fact that the example i see in kfs... they are being used in conjunction with one another? location of the method at the end of kim type service base also leads me to believe this was an afterthought, and perhaps refatoring should have been done to make all validate methods return an attribute set instead of a boolean?
          Ailish sent the following to the Rice dev list in response to a question about the purpose of these different methods, notice her concern on the differences in return types for these:
           

          validateUnmodifiableAttributes: make sure the values on the assignment that are considered keys are not changed during an edit... for example for accounting organization hierarchy... chart, org, and doc type cannot change during an edit... but from and to amount and override code can

           

          fwiw - i worry about the variation in which methods return List<String> vs. AttributeSet vs. boolean here

           

          not sure if you're looking at kfs code, but the best reference implementations would be there.
          Ailish sent the following to the Rice dev list in response to a question about the purpose of these different methods, notice her concern on the differences in return types for these:

          validateAttributes: make sure the values are the right size and shape and if there is a reference table that they exist and are active

          validateUniqueAttributes: make sure the principal doesn't have another assignment with the same values for these unique attributes

           

          validateAttributesAgainstExisting: *seems* like this is just giving the opportunity to provide a good error for validateUniqueAttributes, given the different return vals and the fact that the example i see in kfs... they are being used in conjunction with one another? location of the method at the end of kim type service base also leads me to believe this was an afterthought, and perhaps refatoring should have been done to make all validate methods return an attribute set instead of a boolean?
           

          validateUnmodifiableAttributes: make sure the values on the assignment that are considered keys are not changed during an edit... for example for accounting organization hierarchy... chart, org, and doc type cannot change during an edit... but from and to amount and override code can

           

          fwiw - i worry about the variation in which methods return List<String> vs. AttributeSet vs. boolean here

           

          not sure if you're looking at kfs code, but the best reference implementations would be there.
          ewestfal Eric Westfall made changes -
          Summary Document various "validate" methods on KimTypeService, also determine if we need to do some work on this interface to make return types more consistent Determine if we need to do some work on the KimTypeService interface to make return types more consistent
          Fix Version/s 1.1 [ 14190 ]
          Fix Version/s 1.0.1 [ 15300 ]
          ewestfal Eric Westfall made changes -
          Fix Version/s 1.1? [ 15811 ]
          Fix Version/s 1.1 [ 14190 ]
          ewestfal Eric Westfall made changes -
          Fix Version/s 1.1? [ 15811 ]
          ewestfal Eric Westfall made changes -
          Fix Version/s 1.1 [ 14190 ]
          ewestfal Eric Westfall made changes -
          Component/s Version Compatibility [ 13202 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Assignee Travis Schneeberger [ tschneeb ]
          jjhanso Jeremy Hanson made changes -
          Fix Version/s 2.0.0-m7 [ 16314 ]
          jjhanso Jeremy Hanson made changes -
          Start Date
          Fix Date 2011-08-08 [ set to sprint end date ]
          jjhanso Jeremy Hanson made changes -
          Original Estimate 2 days [ 57600 ]
          Remaining Estimate 2 days [ 57600 ]
          Hide
          tschneeb Travis Schneeberger added a comment -

          validateUnmodifiableAttributes() & validateUniqueAttributes() should probably not be on the service interface. Instead this validation checks should just be done by validateAttributesAgainstExisting(). The reasoning behind this is unmodifiable & uniqueness checks are just a type of validation against an existing attribute.

          Show
          tschneeb Travis Schneeberger added a comment - validateUnmodifiableAttributes() & validateUniqueAttributes() should probably not be on the service interface. Instead this validation checks should just be done by validateAttributesAgainstExisting(). The reasoning behind this is unmodifiable & uniqueness checks are just a type of validation against an existing attribute.
          Hide
          riceci Rice-CI User (Inactive) added a comment -
          Show
          riceci Rice-CI User (Inactive) added a comment - Integrated in rice-trunk-nightly #126 (See http://ci.rice.kuali.org/job/rice-trunk-nightly/126/ ) KULRICE-3319 , KULRICE-5404
          tschneeb Travis Schneeberger made changes -
          Status Open [ 1 ] Resolved [ 5 ]
          Resolution Fixed [ 1 ]
          Hide
          jcoltrin Jessica Coltrin (Inactive) added a comment -

          Closing since these items are now in the release notes.

          Show
          jcoltrin Jessica Coltrin (Inactive) added a comment - Closing since these items are now in the release notes.
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Status Resolved [ 5 ] Closed [ 6 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow custom [ 73322 ] Copy of custom for rice [ 211187 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow Copy of custom for rice [ 211187 ] custom [ 220935 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow custom [ 220935 ] Rice Workflow [ 230683 ]

            People

            • Assignee:
              tschneeb Travis Schneeberger
              Reporter:
              ewestfal Eric Westfall
            • Votes:
              0 Vote for this issue
              Watchers:
              0 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 2 days
                2d
                Remaining:
                Remaining Estimate - 2 days
                2d
                Logged:
                Time Spent - Not Specified
                Not Specified