Configuring Contrail Observer jobs

Using the Contrail Observer, you can retrieve topology data from Juniper Network Contrail Release 4.1 via REST APIs exposed by the Contrail API server. This observer is developed against Juniper Network Contrail that integrates with OpenStack orchestration platform (Ubuntu 18.04 + Contrail Cloud - Ocata).

Before you begin

Important: The Contrail Observer supports the on-premise Contrail version 4.1.0.

Ensure you have the Contrail API Server and OpenStack credentials details to hand. For rabbitmq jobs, you must also specify the location of the RabbitMQ queue and its authentication details. 

The Contrail observer is installed as part of the core installation procedure.

About this task

Contrail Observer jobs retrieve topology data from Juniper Network Contrail Release 4.1 via REST APIs exposed by the Contrail API server. The observer loads and updates the resources and their relationships within the Netcool Agile Service Manager core topology service.

You define and start the following jobs.
Rabbitmq Listen job
A long-running job that monitors its source for updates and runs until it is explicitly stopped, or until the Observer is stopped.
This job loads all supported resources during startup, and listens to RabbitMQ messages from 'vnc_config.object-update' fanout exchange.
There is no need to run the restapi job before running the rabbitmq job, because the rabbitmq job performs a restapi job during initialization.
Restapi Load job
This job loads all supported resources.
Run this job whenever you need the Contrail topology data refreshed.
By default, these jobs are one-off, transient jobs that perform a full upload of all requested topology data as soon as they are triggered.
You can also run these jobs (again) manually from the Observer UI, or schedule them to run at set times when configuring them.

Procedure

  1. On the Observer jobs page, perform one of the following actions:
    To edit an existing job
    Open the List of options overflow menu next to the job and click View & edit.
    To create a new job
    Click Add a new job + and select the Contrail Observer tile.
    Choose either restapi or rabbitmq from the job type drop-down.
  2. Edit or enter the following parameters, then click Save to save your job and begin retrieving information.
    Table 1. Contrail Observer rabbitmq job parameters
    Parameter Action Details
    Unique ID Enter a unique name for the job. Required
    RabbitMQ hostname or IP address Enter a hostname or IP address for the RabbitMQ server. Required
    RabbitMQ port Specify the port for connection. Required
    RabbitMQ username Specify the username for authentication with RabbitMQ. Required
    RabbitMQ password Enter the password for authentication with RabbitMQ. Required. Use plain text.
    RabbitMQ virtual host Enter the RabbitMQ virtual hostname Optional. Default is /.
    Contrail API URL Specify the URL for the Contrail API server. Required
    OpenStack Authentication URL Enter the authentication URL for the identity service. Required
    OpenStack username Specify the OpenStack user name to connect as (or to). Required
    OpenStack password Specify the OpenStack password with which to authenticate. Required. Use plain text.
    Authentication type Specify the authentication type used. Optional. The default is Keystone, the other option is None.
    OpenStack project domain name Specify the OpenStack project domain name. Optional
    OpenStack user domain name Specify the OpenStack project user domain name. Optional
    OpenStack project name Enter the OpenStack project name for version 3 authentication Optional
    OpenStack tenant name Enter the OpenStack tenant name for version 2 authentication Optional
    OpenStack identity API version Select an option from the dropdown list. Optional
    Connection and read timeout (miliseconds) Choose the time at which the connection and read action times out. Optional. Must be a value greater than 0 (zero). The default is 5000 (5 seconds).
    Access scope

    Enter text to provide a scope for the resources.

    Access scope can help map alerts to resources when resources in different scopes share the same parameters, such as matchTokens.

    Optional.
    Tip: You can define access scope for locations, project names, namespaces, etc.
    Generate debug support file
    Set the optional Generate debug support file parameter to 'True' in order to capture the output of the next scheduled job run as a file. This file will be stored with an observer's log files and can be used to debug observer issues, for example at the request of your designated Support team, or while using a test environment. For one-off jobs (that is, Load jobs), this parameter reverts to 'False' after the next completed run. To examine the output produced, you can load the generated debug file using the File Observer. The file is saved to the following locations:
    On-prem
    $ASM_HOME/logs/<obs>-observer/
    On OCP
    /var/log/itsm/<obs>-observer
    Optional
    Observer job description Enter additional information to describe the job. Optional
    Job schedule

    Specify when the job should run, and whether it should run at regular intervals.

    By default the job runs immediately, and only once.

    Optionally you can specify a future date and time for the job to run, and then set it to run at regular intervals after that.

    Optional. Transient (one-off) jobs only.

    If you set a job schedule, the run intervals must be at least 90 seconds apart, and if you set them at less than 15 minutes, a warning is displayed, as the frequency can impact system performance.

    Table 2. Contrail Observer restapi job parameters
    Parameter Action Details
    Unique ID Enter a unique name for the job. Required
    Contrail API URL Specify the URL for the Contrail API server. Required
    OpenStack Authentication URL Enter the authentication URL for the identity service. Required
    OpenStack username Specify the OpenStack user name to connect as (or to). Required
    OpenStack password Specify the OpenStack password with which to authenticate. Required. Use plain text.
    Authentication type Specify the authentication type used. Optional. The default is Keystone, the other option is None.
    OpenStack project domain name Specify the OpenStack project domain name. Optional
    OpenStack user domain name Specify the OpenStack project user domain name. Optional
    OpenStack project name Enter the OpenStack project name for version 3 authentication Optional
    OpenStack tenant name Enter the OpenStack tenant name for version 2 authentication Optional
    OpenStack identity API version Select an option from the dropdown list. Optional
    Connection and read timeout (miliseconds) Choose the time at which the connection and read action times out. Optional. Must be a value greater than 0 (zero). The default is 5000 (5 seconds).
    Access scope

    Enter text to provide a scope for the resources.

    Access scope can help map alerts to resources when resources in different scopes share the same parameters, such as matchTokens.

    Optional.
    Tip: You can define access scope for locations, project names, namespaces, etc.
    Generate debug support file
    Set the optional Generate debug support file parameter to 'True' in order to capture the output of the next scheduled job run as a file. This file will be stored with an observer's log files and can be used to debug observer issues, for example at the request of your designated Support team, or while using a test environment. For one-off jobs (that is, Load jobs), this parameter reverts to 'False' after the next completed run. To examine the output produced, you can load the generated debug file using the File Observer. The file is saved to the following locations:
    On-prem
    $ASM_HOME/logs/<obs>-observer/
    On OCP
    /var/log/itsm/<obs>-observer
    Optional
    Observer job description Enter additional information to describe the job. Optional
    Job schedule

    Specify when the job should run, and whether it should run at regular intervals.

    By default the job runs immediately, and only once.

    Optionally you can specify a future date and time for the job to run, and then set it to run at regular intervals after that.

    Optional. Transient (one-off) jobs only.

    If you set a job schedule, the run intervals must be at least 90 seconds apart, and if you set them at less than 15 minutes, a warning is displayed, as the frequency can impact system performance.