Uploaded image for project: 'Jira Service Management Data Center'
  1. Jira Service Management Data Center
  2. JSDSERVER-14736

Some users are not able to search for objects with attribute type Object due to IQLValidationException: No matching attribute for AQL clause ()

      Issue Summary

      Some users are not able to search for objects with attribute type Object due to IQLValidationException: No matching attribute for AQL clause ()

      This is reproducible on Data Center: yes

      Steps to Reproduce

      1. On a JSM instance with version below 4.20.25, prepare a schema with a few object types.
      2. In one of the object types, create an attribute type Object to reference it to another object type.
      3. Insert an AQL to filter the objects for this attribute.
      4. Create objects accordingly and make sure objects are being filtered properly.
      5. Add a non-admin user to the Object Schema Developer role, and leave all other Object type level roles unassigned.
      6. Log in as this user, edit an object, and edit the attribute with the type of Object. This user should be able to search for an object and update the attribute value successfully.
      7. Upgrade this instance to >=4.20.25.
      8. Copy the schema and leave it as it is.
      9. Repeat step 6 on the original schema.
      10. Delete the cloned schema.
      11. Repeat step 6 again.

      Expected Results

      Without any intentional changes, users who used to be able to edit objects can still edit the same objects after upgrade

      Actual Results

      After upgrade, some users face issue when editing some objects/object attributes. The below exception is thrown in the atlassian-jira.log file.

      2023-10-04 07:05:24,634+0000 http-nio-8080-exec-5 url: /jira/rest/insight/1.0/objecttype/104/objects; user: testuser INFO testuser 425x1184x1 wveuqs 185.53.145.95,172.50.0.1 /rest/insight/1.0/objecttype/104/objects [c.r.j.p.i.services.util.ServiceUtil] InsightException:IQLValidationException: No matching attribute for AQL clause ("Server" = ad-1234)
      com.riadalabs.jira.plugins.insight.common.exception.IQLValidationException: IQLValidationException: No matching attribute for AQL clause ("Server" = ad-1234)
      

      Other symptoms are

      • A pop-up screen that says

        The Jira server was contacted but has returned an error response. We are unsure of the result of this operation.

      • The attribute which should allow users to search for objects and select it as value doesn't suggest any objects
      • HTTP status 400 is returned with an error "No matching attribute for AQL clause" in the response

      By enabling debug for com.riadalabs.jira.plugins.insight.services, we'll find that the permission of the affected user is being checked for an irrelevant object type (which is in a different schema and this user shouldn't have permission to).

      2023-10-04 07:05:24,634+0000 http-nio-8080-exec-5 url: /jira/rest/insight/1.0/objecttype/104/objects; user: testuser DEBUG testuser 425x1184x1 wveuqs 185.53.145.95,172.50.0.1 /rest/insight/1.0/objecttype/104/objects [c.r.j.p.i.services.permission.InsightPermissionServiceImpl] hasInsightPermission (InsightUser{key=JIRAUSER11102}, 5, 271)
      

      Workaround

      If possible, grant the affected users Object Schema Developers or Object Type Developers role in the copied schema(s)

            [JSDSERVER-14736] Some users are not able to search for objects with attribute type Object due to IQLValidationException: No matching attribute for AQL clause ()

            No work has yet been logged on this issue.

              3d5a17e800ca Yufei Zuo
              michin Michelle Chin
              Affected customers:
              14 This affects my team
              Watchers:
              27 Start watching this issue

                Created:
                Updated:
                Resolved: