Microsoft Provisioning System Best Practices: Delete at the end of a transaction
When developing an MPF Named Procedure that includes ANY type of deletion action in it, make sure to put the actual delete action at the end. This is true for all standard MPF providers (Active Directory, Exchange, File System, IIS, etc.). This is because there is no way to roll back or compensate for a deleted action. Thus, during a provisioning request/transaction, if there are a number of steps being performed (such as update database, update user, delete IIS site) you should make the deletion action as the last possible action.
The reason for this is due to the uniqueness of objects. Let's say you deleted a user object in Active Directory and then wrote to a SQL Database for logging. If the logging action failed, you could recreate the same object (in practice, the Active Directory provider will not do this) with all of the same settings and group memberships. But in actuality, this will not be the "same user" as the user now has a different SID and GUID.