Uploaded image for project: 'MidPoint'
  1. MidPoint
  2. MID-2222

Associations and multivalue attributes used as "valueAttribute"

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 3.1 (Sinan)
    • Fix Version/s: 3.1.1
    • Component/s: None
    • Labels:
      None

      Description

      OpenLDAP, posixGroup configuration.

      This does not work for associations:

      			<association>
      				<ref>ri:group</ref>
      				<displayName>LDAP Group Membership</displayName>
      				<kind>entitlement</kind>
      				<intent>ldapGroup</intent>
      				<direction>objectToSubject</direction>
      				<associationAttribute>ri:memberUid</associationAttribute>
      				<valueAttribute>ri:uid</valueAttribute>
      			</association>
      

      Attribute ri:uid is the problem, because in LDAP schema it's multivalue. Getting user causes:

      com.evolveum.midpoint.util.exception.SystemException: java.lang.IllegalStateException: Attempt to get single value from property {http://midpoint.evolveum.com/xml/ns/public
      /resource/instance-3}uid with multiple values
              at com.evolveum.midpoint.provisioning.consistency.impl.ErrorHandlerFactory.createErrorHandler(ErrorHandlerFactory.java:90) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ShadowCache.handleError(ShadowCache.java:673) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ShadowCache.getShadow(ShadowCache.java:311) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ProvisioningServiceImpl.getObject_aroundBody0(ProvisioningServiceImpl.java:274) [provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ProvisioningServiceImpl$AjcClosure1.run(ProvisioningServiceImpl.java:1) [provisioning-impl-3.2-SNAPSHOT.jar:na]
              at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149) [aspectjrt-1.7.3.jar:na]
              at com.evolveum.midpoint.util.aspect.MidpointAspect.wrapSubsystem(MidpointAspect.java:178) [util-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.util.aspect.MidpointAspect.ajc$inlineAccessMethod$com_evolveum_midpoint_util_aspect_MidpointAspect$com_evolveum_midpoint_util_aspect_MidpointAspect$wrapSubsystem(MidpointAspect.java:1) [util-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.util.aspect.MidpointAspect.processProvisioningNdc(MidpointAspect.java:68) [util-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ProvisioningServiceImpl.getObject(ProvisioningServiceImpl.java:154) [provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.model.impl.ModelObjectResolver.getObject(ModelObjectResolver.java:158) [model-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.model.impl.controller.ModelController.getObject_aroundBody0(ModelController.java:288) [model-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.model.impl.controller.ModelController$AjcClosure1.run(ModelController.java:1) [model-impl-3.2-SNAPSHOT.jar:na]
              at org.aspectj.runtime.reflect.JoinPointImpl.proceed(JoinPointImpl.java:149) [aspectjrt-1.7.3.jar:na]
      ...
      Caused by: java.lang.IllegalStateException: Attempt to get single value from property {http://midpoint.evolveum.com/xml/ns/public/resource/instance-3}uid with multiple values
              at com.evolveum.midpoint.prism.PrismProperty.getValue(PrismProperty.java:113) ~[prism-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.EntitlementConverter.createQuery(EntitlementConverter.java:247) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.EntitlementConverter.postProcessEntitlementEntitlementToSubject(EntitlementConverter.java:203) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.EntitlementConverter.postProcessEntitlementsRead(EntitlementConverter.java:115) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ResourceObjectConverter.postProcessResourceObjectRead(ResourceObjectConverter.java:1503) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ResourceObjectConverter.fetchResourceObject(ResourceObjectConverter.java:1082) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ResourceObjectConverter.getResourceObject(ResourceObjectConverter.java:159) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              at com.evolveum.midpoint.provisioning.impl.ShadowCache.getShadow(ShadowCache.java:277) ~[provisioning-impl-3.2-SNAPSHOT.jar:na]
              ... 113 common frames omitted
      

        Attachments

          Activity

            People

            Assignee:
            vix Ivan Noris
            Reporter:
            vix Ivan Noris
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Dates

              Created:
              Updated:
              Resolved: