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

Determine best way to determine whether KRAD criteria fields treat wildcards and operators as literals

    Details

    • Type: New Feature
    • Status: Open
    • Priority: Critical
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: 2.6
    • Component/s: Development, JPA, Roadmap
    • Security Level: Public (Public: Anyone can view)
    • Labels:
    • Rice Module:
      KNS, KRAD
    • KRAD Feature Area:
      Persistence Framework
    • Sprint:
      2.4.0-rc1 Sprint 7, 2.4.0-rc1 Sprint 8
    • KAI Review Status:
      Not Required
    • KTI Review Status:
      Not Required
    • Include in Release Notes?:
      Yes

      Description

      Legacy lookups invoked KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName) when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them.

      See

      • LookupCriteriaGeneratoreBase.getCollectionCriteriaFromMapUsingPrimaryKeysOnly
      • LookupCriteriaGeneratoreBase.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral
      • LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral

        Attachments

          Activity

          ewestfal Eric Westfall created issue -
          ahamid Aaron Hamid (Inactive) made changes -
          Field Original Value New Value
          Link This issue cloned to KULRICE-9388 [ KULRICE-9388 ]
          ahamid Aaron Hamid (Inactive) made changes -
          Link This issue cloned to KULRICE-9388 [ KULRICE-9388 ]
          ahamid Aaron Hamid (Inactive) made changes -
          Description LookupDao implementations are parsing lookup expressions and constructing and executing native OJB and JPQL queries. This logic needs to be converted such that the resultant query can be executed by the DataObjectService/PersistenceProvider {{findMatching}} methods which take the portable {{QueryByCriteria}} query/criteria abstraction. Legacy lookups invoked {{KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName)}} when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them.
          ahamid Aaron Hamid (Inactive) made changes -
          Description Legacy lookups invoked {{KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName)}} when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them. Legacy lookups invoked {{KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName)}} when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them.

          See {{LookupCriteriaGeneratoreBase.getCollectionCriteriaFromMapUsingPrimaryKeysOnly}}, {{LookupCriteriaGeneratoreBase.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}, {{LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}
          ahamid Aaron Hamid (Inactive) made changes -
          Description Legacy lookups invoked {{KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName)}} when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them.

          See {{LookupCriteriaGeneratoreBase.getCollectionCriteriaFromMapUsingPrimaryKeysOnly}}, {{LookupCriteriaGeneratoreBase.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}, {{LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}
          Legacy lookups invoked {{KNSServiceLocator.getBusinessObjectDictionaryService().isLookupFieldTreatWildcardsAndOperatorsAsLiteral(businessObjectClass, fieldName)}} when generating criteria queries. We need to determine the correct way to perform the equivalent in KRAD (in LookupCriteriaGeneratorQBC), given there is no analogous mapping in the DataDictionary. The KRAD LookupInputField contains the flag which specifies how the field interprets wildcards and operators. Criteria fields are defined on LookupViews, so the most straightforward strategy seems to be to iterate through those definitions to obtain the LookupInputFields. Since this is called in a loop over all criteria fields, we should make sure to return a map of the settings for all fields in the lookup view to avoid repeatedly iterating over them.

          See

          * {{LookupCriteriaGeneratoreBase.getCollectionCriteriaFromMapUsingPrimaryKeysOnly}}
          * {{LookupCriteriaGeneratoreBase.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}
          * {{LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral}}
          ewestfal Eric Westfall made changes -
          Assignee Aaron Hamid [ ahamid ] Jonathan Keller [ jkeller ]
          Hide
          ewestfal Eric Westfall added a comment -

          Assigned to Jonathan. Jonathan this is the thing we talked about in the checkpoint the other day. Essentially, Aaron checked in a "naive" solution in the LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral method. Note how in this method is going to fetch the view every single time it's called which will most certainly be inefficient.

          Show
          ewestfal Eric Westfall added a comment - Assigned to Jonathan. Jonathan this is the thing we talked about in the checkpoint the other day. Essentially, Aaron checked in a "naive" solution in the LookupCriteriaGeneratorQBC.doesLookupFieldTreatWildcardsAndOperatorsAsLiteral method. Note how in this method is going to fetch the view every single time it's called which will most certainly be inefficient.
          ewestfal Eric Westfall made changes -
          Epic Link KULRICE-9502 [ 115340 ]
          ewestfal Eric Westfall made changes -
          Original Estimate 3 hours [ 10800 ]
          ewestfal Eric Westfall made changes -
          Remaining Estimate 3 hours [ 10800 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow custom [ 198660 ] Copy of custom for rice [ 207960 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow Copy of custom for rice [ 207960 ] custom [ 217708 ]
          spatterson Shem Patterson (Inactive) made changes -
          Workflow custom [ 217708 ] Rice Workflow [ 227456 ]
          Hide
          jkeller Jonathan Keller added a comment -

          So - we need to pass through a list of properties which should not be processed for wildcards to the lookup methods. This isn't information that the lookup service should be responsible for retrieving.

          I would argue that the LookupService should be as independent of the view as possible, since there are use cases for calling these methods from non UI code.

          Show
          jkeller Jonathan Keller added a comment - So - we need to pass through a list of properties which should not be processed for wildcards to the lookup methods. This isn't information that the lookup service should be responsible for retrieving. I would argue that the LookupService should be as independent of the view as possible, since there are use cases for calling these methods from non UI code.
          ewestfal Eric Westfall made changes -
          Rank Ranked higher
          cniesen Claus Niesen made changes -
          Rank Ranked lower
          cniesen Claus Niesen made changes -
          Rank Ranked lower
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 8 [ 247 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 8 [ 247 ] 2.4.0-rc1 Sprint 7 [ 246 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Rank Ranked higher
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 7 [ 246 ] 2.4.0-rc1 Sprint 8 [ 247 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 8 [ 247 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Rank Ranked lower
          gilesp Peter Giles (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 7 [ 246 ]
          gilesp Peter Giles (Inactive) made changes -
          Rank Ranked lower
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Sprint 2.4.0-rc1 Sprint 7 [ 246 ] 2.4.0-rc1 Sprint 7, 2.4.0-rc1 Sprint 8 [ 246, 247 ]
          jcoltrin Jessica Coltrin (Inactive) made changes -
          Rank Ranked higher
          ewestfal Eric Westfall made changes -
          Epic Link KULRICE-9502 [ 115340 ]
          gilesp Peter Giles (Inactive) made changes -
          Fix Version/s 2.4.1 [ 17516 ]
          Fix Version/s 2.4 [ 16913 ]
          kbtaylor Kristina Taylor (Inactive) made changes -
          Fix Version/s 2.5 [ 17044 ]
          Fix Version/s 2.4.1 [ 17516 ]
          kbtaylor Kristina Taylor (Inactive) made changes -
          Rank Ranked higher
          kbtaylor Kristina Taylor (Inactive) made changes -
          Fix Version/s 2.6 [ 17820 ]
          Fix Version/s 2.5 [ 17044 ]
          ewestfal Eric Westfall made changes -
          Labels Old

            People

            • Assignee:
              jkeller Jonathan Keller
              Reporter:
              ewestfal Eric Westfall
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Time Tracking

                Estimated:
                Original Estimate - 3 hours
                3h
                Remaining:
                Remaining Estimate - 3 hours
                3h
                Logged:
                Time Spent - Not Specified
                Not Specified