Using iTop

Creating your iTop

iTop Customization

"How to" examples

User Interface

Automation & Ticket management

Portal Customization

You are browsing the documentation for iTop 3.1 which is not the current version.

Consider browsing to iTop 3.2 documentation

Define Obsolescence rules

Prerequisite: You must be familiar with the Syntax used in Tutorials and have already created an extension.

Define which objects are under obsolescence, thus filtered
XML, Constrain
min version:

Get familiar with Obsolescence before using it.

How is it defined

  • Obsolescence is defined on a class per class basis.
  • A obsolescence condition is an OQL expression, using any field of the class, including those of type AttributeExternalField
  • Obsolescence condition are inherited from parent classes, but can be redefined on a child class.
  • If no obsolescence condition is defined on a class and none of its parent, then objects of that class are never considered as obsolete.
itop_design / classes / class@Organization
        <obsolescence _delta="redefine">
An object with its status undefined (= no value = ISNULL), is not considered as obsolete by default. If you want to have undefined status considered as obsolete then use this condition:
itop_design / classes / class@Organization / properties
        <obsolescence _delta="redefine">
          <condition><![CDATA[status='inactive' OR ISNULL(status)=1]]></condition>


Based on object status combined with status of a parent if parent exists :

itop_design / classes / class@Hypervisor / properties / obsolescence
        <![CDATA[status = 'obsolete' OR (server_id != 0 AND server_id_obsolescence_flag)]]>
Adding a sophisticated obsolescence condition may lead to exceed the 61 tables limitation of MySQL. In such a case, the symptom is: MySQL can only use 61 tables in a join, mysql_errno = 1116. An example of sophisticated condition is to base the obsolescence of a Virtual Machine on the obsolescence of its Hypervisor.

Combination of status and delay:

itop_design / classes / class@Ticket / properties / obsolescence
  ( close_date < DATE_FORMAT(DATE_SUB(NOW(), INTERVAL 15 MONTH),'%Y-%m-%d 00:00:00') 
       last_update < DATE_FORMAT(DATE_SUB(NOW(), INTERVAL 15 MONTH),'%Y-%m-%d 00:00:00')
The above obsolescence rule has a negative impact on query performance as query cache is ignored because NOW() returns a date-time which is changing every second. With MySQL 8, query cache is no more used.
3_1_0/customization/obsolescence.txt ยท Last modified: 2023/07/21 10:19 (external edit)
Back to top
Contact us