TCPClientStitcherd

Overview

The Unified Assurance Topology TCP Client Stitcher connects to a server and listens for messages, then processes anything received through rules files for inclusion into the Topology and Graph frameworks.

Although generic enough to be able to stitch any type of TCP message from a device for use in the Topology module, the Topology TL1 Stitcher service has been setup to stitch TL1 Gateways and Elements to build a dynamic logical layout.

TCP Client Stitcher Setup

  1. Determine the host and port settings needed to establish a client connection.

  2. Review the logic in the rules files referenced in the configuration to see the processing that will be done when messages are retrieved:

    • "LoadRules" will be run during application startup to load data that might be needed during processing.

    • "IncludeRules" will be read during application startup to load additional files that might be called during processing.

    • "BaseRules" will be run for each device that is selected based on the configuration.

    Update the logic as needed.

  3. Create a clone of the default service, making changes to the configuration as needed.

  4. Enable the Service.

    Configuration -> Broker Control -> Services

Default Service

Field Value
Package Name coreCollection-app
Service Name Topology TL1 Stitcher
Service Program bin/core/collection/TCPClientStitcherd
Service Arguments
Service Description Topology and Inventory rules-based TL1 stitcher via Core TL1 Gateway
Failover Type Standalone (Supported: Standalone, Primary/Backup)
Status Disabled
Privileged (Checked)

Default Configuration

Name Value Possible Values Notes
BaseRules collection/topology/tl1g/base.rules Text, 255 characters Relative path to Base Rules.
BranchDir core/default Text, 255 characters relative path to Rules dir.
Host 127.0.0.1 Text, 255 characters The FQDN/IP Address of the device to be connected to.
IncludeRules collection/topology/tl1g/base.includes Text, 255 characters Relative path to Include Rules.
LoadRules collection/topology/tl1g/base.load Text, 255 characters Relative path to Load Rules.
LogFile logs/ToplogyTL1Stitcher.log Text, 255 characters Relative path to Log File.
LogLevel ERROR OFF, FATAL, ERROR, WARN, INFO, DEBUG Logging level used by application.
Port 9000 Integer The port to use when connecting to the device.
Threads 3 Integer The number of process threads created.

Rules

This stitcher uses the Unified Assurance standard rules architecture, which are 100% Perl syntax. Refer to the following articles to assist in rules creation:

Tokens

The stitcher exposes the following tokens for rules processing by the listeners.

Token Description
$Message->{'RxTime'} Time of message
$Message->{'Message'} Processed full TL1 Message (semicolon delimited)
$Message->{'Host'} Hostname
$Message->{'IP'} IP Address
$AppConfig Hash reference to the application configuration name-value pairs that were configured. (i.e. use $AppConfig->{'Host'} to retrieve the set value for 'Host'.)
$CustomHash Custom key, value cache available across all rules. Contents commonly defined in Load Rules then used in Base or other rules. NOTE: This variable is a shared object and any additional sub hashes or arrays must be shared before use or it will cause the error: "Invalid value for shared scalar". Instantiate the sub hash/array using '&share({})' e.g.
$CustomHash->{SubObject} = &share({});
$StorageHash Internal cache used as the StorageHash option when calling rules functions such as FindDeviceID(). NOTE: The structure of this cache is subject to change! Not recommended for custom global storage or manual manipulation; use $CustomHash.

Administration Details

The following list shows the technical details you will need for advanced administration of the application: