다음을 통해 공유


MIIS Deprovisioning and using ShouldDeleteFromMV

In general, MIIS solutions have one connected data source that is authoritative for deletes and drives the deprovisioning process.  A common MIIS configuration is to set the object deletion rule to delete the MV object when the connector is removed from this authoritative MA.  This will cause a MV delete and trigger all other MA's deprovisioning action.

What if you want a MA to be authoritative for deletes, but you also want to use some logic to control the delete?  The metaverse rules extension contains a function "ShouldDeleteFromMV" that will allow you to have more control of the object deletion rule.  This object has the csentry as a parameter and allows you to look at the csentry or mventry attributes and make a decision on deletion. You do need to also make sure the csentry comes from the above mentioned authoritative MA.  Otherwise, your deletes could even be triggered from clearing out some "innocent" connector space.  The code below shows a possible implementation of this.  Test out your code for this type of function to make sure you have it right.

Code

'If csentry is not coming from my authoritative MA, then I must not delete it (or some other logic could kick in)
If csentry.MA.Name = "Authoritative MA Name" Then
   'Check status attribute that is created by some MA
   If mventry("someStatusAttribute").IntegerValue = 5 Then
      'In my case, I am importing homeMDB into the metaverse and not deleting the value if a mailbox has been created.
If Not mventry("homeMDB").IsPresent Then
ShouldDeleteFromMV = True
Else
ShouldDeleteFromMV = False
End If
End If
Else
ShouldDeleteFromMV = False
End If