How to prevent CIs from being created/updated
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
07-31-2025 11:55 AM
Hello community,
I'm currently working with Discovery for the IP Routers class, however I need to avoid the creation / update of records with "retired" on the name. And I'm asked to remediate it using the Identificaiton and Reconciliaiton Engine, is this possible, or a Bussiness Rule would be necessary to avoid these records being created? If possible with the IRE, how would you approach the task?
Thanks in advanced!
- Labels:
-
Data Acquisition
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2025 01:18 AM
Hi @Community Alums ,
As per my understanding solution from ServiceNow perspective will be
By design, the IRE itself is responsible only for:
* Identifying if an incoming payload matches an existing CI
* Deciding to insert or update (based on identification & reconciliation rules)
* Enforcing write protect rules based on reconciliation definitions
But:
IRE does not have a built-in mechanism to filter out or skip an incoming CI based on field content like “name contains retired.”
It only decides where to write and what fields it can write to.
So what are your options?
Option 1: Use IRE (limited)
IRE itself cannot fully prevent the creation of new CIs whose name contains "retired".
What it can do:
* You could create a reconciliation definition for cmdb_ci_ip_router
* Add a condition in reconciliation definition to prevent updates to certain fields if name contains 'retired'
But:
* This won't stop creation of a new CI; it would only block field updates if it already exists.
Option 2 (recommended): Use a Business Rule or Transform Script
This is the standard, supported approach:
* Write a Business Rule on cmdb_ci_ip_router:
* before insert and before update
* If name contains "retired", abort the insert/update.
if (current.name && current.name.toLowerCase().indexOf('retired') != -1) {
gs.addErrorMessage('CI creation/update skipped because name contains "retired".');
current.setAbortAction(true);
}
This will:
* Fully prevent creating or updating such CIs.
* Centralized logic.
* Easy to maintain.
Option 3: Pre-process the payload (advanced)
If you use Discovery patterns, you could:
* Add a script step in the pattern’s exploration phase
* If discovered name contains "retired", skip the step or stop processing
But:
* This requires modifying the OOTB pattern → better to extend.
Best practice from ServiceNow:
Use IRE for field-level governance & reconciliation only
Use Business Rules or pattern logic for record-level conditional logic (e.g., skip creation based on name, status, custom logic)
Please appreciate the efforts of community contributors by marking appropriate response as Mark my Answer Helpful or Accept Solution this may help other community users to follow correct solution in future.
Thank You
AJ - TechTrek with AJ - ITOM Trainer
LinkedIn:- https://www.linkedin.com/in/ajay-kumar-66a91385/
YouTube:- https://www.youtube.com/@learnitomwithaj
Topmate:- https://topmate.io/aj_techtrekwithaj (Connect for 1-1 Session)
ServiceNow Community MVP 2025
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
08-01-2025 01:34 AM
Hi @Community Alums
I have tried the similar use case recently with IRE.
When you will add the condition to filter the "retired" CI, it will prevent the updates but still allow the creation of new records. This led to duplicate entries in the CMDB.
A scalable solution would be a generic Business Rule on cmdb_ci, with logic targeting specific classes like IP Router. More classes can be added as needed.
As there are so many new features are coming before implementing a BR, raise a HI case to confirm if there's a platform-level configuration to handle this natively.