File-based discovery process
After the discovery, the discovered devices and their resources are stored in Cassandra database in the Inventory Service.
Discovery formulas
Discovery rules are available in the as predefined discovery formulas for specific vendors and technologies. These discovery formulas are used by Telco Network Cloud Manager - Performance to discover the vendor-specific devices and their resources.
{
"resource" : "deviceIP=10.71.214.65, deviceID=7340054, deviceName=FTTO_Test1, resourceID=NE:7340054;FR:0;S:5;CP:-1;PP:--0-;ONU:0, id=FTTO_Test1/Frame:0/Slot:5/Port:0/ONU ID:0, type=huaweiGponOnt, granularityPeriod=15, indicatorGroupID=IG80112",
"time" : 1526372100000,
"tpe" : "NUMBER",
"kpi" : "upAverageThroughput",
"value" : "110.00"
}
After the Technology Pack is installed, you can see the discovery formulas in the following
location:
/opt/basecamp/file-collector/content/discoveries/<tech_pack>.
The discovery formulas have .discovery as the file extension. These formulas
contain additional discovery rules to obtain more information about the resources, properties, and
their relationships.
- Device discovery rule
These rules are used in discovery formulas in built-in Technology Packs for resource discovery to create or enrich in-band discovered resources and the relation discovery (stitch) to create relations among the resources.
For example,engine file when resource.type like 'cabinet' select * from local.cabinet set vendor = 'cabinet' set prop2 = resource.prop2 unset prop1
- Resource and properties discovery rules that are specific to a resource type.Optionally, formulas can contain discovery rules to obtain additional properties. For example,
engine file when resource.type like 'cabinet' select * from local.<reousrce_type> set prop1 = <reousrce_type>.prop1 set prop2 = <reousrce_type>.prop2 set prop2 = <reousrce_type>.prop3
- Resource relationship rulesFor example,
engine file relate device to cabinet as contain when target.name == source.prop2
engine file
when resource.vendor like 'Nokia'
select deviceName from local.gponIgmpCard UNION ALL select deviceName from local.gponMulticastSystem UNION ALL select deviceName from local.gponInterface UNION ALL select deviceName from local.gponEthernetLag UNION ALL select deviceName from local.gponCard UNION ALL select deviceName from local.gponOnt UNION ALL select deviceName from local.gponUniPort UNION ALL select deviceName from local.gponVoice UNION ALL select deviceName from local.gponOntEthernetPort UNION ALL select deviceName from local.gponVlan UNION ALL select deviceName from local.gponBridgePortVlan UNION ALL select deviceName from local.gponXdsl
set id = resource.deviceName
set name = resource.deviceName
set type = 'device'
set vendor = 'Nokia'
Discovery model files
- /opt/itoa/services/inventory/content/model/PropertyThe model files have .model as the file extension. Every resource type has its own property model file that describes all the properties that are available in that resource type. For example, the contents of gponCard.model file is as follows:
type gponCard extends snmpPollable{ property index String{ required = true } property vendor String property id String property hwFrameType String property tpFrameId String property tpSlotId String property hwSerialNumber String property cardType String property sysName String property deviceType String property portType String property displayName String property deviceName String property deviceIP String property objectID String property cardID String property portSlot String property portShelf String property portRack String property portPort String property card String property portCard String property deviceID String property resourceID String property granularityPeriod String property waitPeriod String property interval String } }
- /opt/itoa/services/inventory/content/model/RelationshipThe model files have .model as the file extension. Every resource type has its own relationship model file that describes the resource grouping based on the resource type and the device. For example, the contents of device-card.model file is as follows:
relationship contain device ->> card
Stages in discovery
Apache NiFi and File Collector Service parse and extract the information from the input files from EMS.