Attribute Metadata is not getting updated for the old identity

Hi,

We had 2 source mapping for an identity attribute. One is from an authoritative source application and another is from Active Directory. We have removed mapping from Active Directory( Updated Identity.xml). However, for the existing identities when the authoritative source attribute value is updated null, the identity attribute source mapping is showing the Active Directory attribute in AttributeMetadata (even though there is no mapping with Active Directory attribute for that identity attribute. We have run the identity refresh with â€˜Refresh identity attributes’ option enabled. But still, it is not getting updated.

In the identity,

<!--

<AttributeMetaData attribute=“xyz” source=“Active Directory:xyz”/>

-->

Can you please help how to resolve this issue?

Thanks in advance

There is no way to purge old AttributeMetadata from identity cube XML. You need to remove it using IIQ Java API suing a one time rule runner task or a refresh rule

You can attempt to resolve the issue by implementing a pre-refresh rule to clear the attribute metadata. To configure a pre-refresh rule for a specific refresh task, you can set the “preRefreshRule” attribute in the TaskDefinition. This attribute is not visible by default, but you can add it to the task properties.

Here is a sample code snippet that can help you achieve this:

if(null!=identity){
   List attributeMetaDataList = identity.getAttributeMetaData();
   if(null!=attributeMetaDataList && !attributeMetaDataList.isEmpty()){
     List attributeMetaDatas = new ArrayList();
     attributeMetaDatas.addAll(attributeMetaDataList);
     for(AttributeMetaData metaData: Util.safeIterable(attributeMetaDatas)){
           identity.remove(metaData);
     }
    try{
      context.saveObject(identity);
      context.commitTransaction();
      log.debug("AttributeMetaData removed for: "+identity.getName());
   }
  catch(Exception e){
     log.error("Exception Encountered in removing the AttributeMetaData: " + e.getMessage());
  }
 }
  else{
     log.debug(“AttributeMetaData not found”);
   }
}
else{
  log.error(“Identity Object not found”);
}

Could we just null out the attribute_meta_data on the spt_identity and then refresh the cube to achieve the same effect ?

It seems to me like an option to “forceRebuildAttributeMapping” would be a useful option on the identity refresh task

@seneca Agreed. Having an option in Identity Refresh would come handy. But you can achieve this in a pre refresh rule like mentioned above.

Would recommend you to put your idea in the Idea Portal: https://ideas.sailpoint.com/

Note: Found a fix? Mark it as a solution! Want to say thanks? Give Kudos to anyone who helped you understand or solve the problem. Thanks..!!!