How to apply IRE to import sets?

Using import set for populating CMDB is always a challenging activity. setting up the right coalesce field to your transform map makes this activity particularly challenging, correctly identify CI primary attribute is a key to reduce the risk of introducing inconsistencies through duplicate records.

Identification and Reconciliation(IRE) framework provides JavaScript API that can be used in import set. by using CMDBTransformUtil class, you don’t need to set coalesce field in your transform map. CMDBTransformUtil class uses Identification rules that already exist to workout what should the primary key for this import.

here is example :Imaging that we want import the below records for windows server

NameSerial NumberOSIP
Server-0090-HPXXXXXXX0000-1Windows 2012
Server-0091-HP Windows 2012

In the absence of IRE & CMDBTransformUtil class , you might have hard time deciding what should be the coalesce key, thankfully, with IRE we don’t have to worry about coalesce key for our transform map .

What we need to do are the following:

  • Check that identification rules are configured for Windows Server(OOTB Identification rules are configured)
  • Create Import Set and transform map for the right server class. make sure all Coalesce fields are set to false

  • Create the OnBefore transform script and use the below script to call CMDB API to do IRE of current row
var cmdbUtilIRE = new CMDBTransformUtil();
cmdbUtilIRE.identifyAndReconcileEnhanced(source, map, log);
ignore = true;

if (cmdbUtilIRE.hasError()) {
        var errorMessage = cmdbUtilIRE.getError();
} else {'IE Output Payload: ' + cmdbUtilIRE.getOutputPayload());'Imported CI: ' +  cmdbUtilIRE.getOutputRecordSysId());

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s