AutoPilot integration is available in XRay versions 1.3 and later and can be set up using the steps in this article. If you installed XRay using deployment pack version 1.5 or later, these steps were completed through the config.sh command.
The benefit of setting up AutoPilot as an external data source for XRay is that policy and sensor data becomes available to jKQL queries.
This article covers the following topics:
- Configuring AutoPilot to function as an external data source for XRay
- Setting up authorization for the data source in global.properties
- Loading the external data source configuration
- Verifying and troubleshooting data source configurations
Configuring AutoPilot to function as an external data source for XRay
From the jkool-dbapi-solr package, run the following commands. Replace -pwd with the value used for the upgrade script.
>bin/jkool-load-ext-data-src.sh -f config/ext-data-src/config-autopilot.xml -pwd <jkql-admin-pwd> [-solr <solr-home>] [-sh <solr-host>] [-sp <solr-port>] [-zh <zookeeper-host>] [-zp <zookeeper-port>] [-zr <zookeeper-root>]
Setting up authorization for the data source in global.properties
The AutoPilot external data source requires external authorization.
To enable external authorization, add the following to global.properties:
Loading the external data source configuration
To load external data source configuration, restart the following Xray components:
- Xray CEP components
- Compute Node (standalone Xray deployments)
- Web Server
Verifying and troubleshooting data source configurations
To verify that external data source configurations are loaded, check the CEP log for the following:
If the external item definition is not found, recycle the XRay CEP Servers.
Try to run a jKQL query to find sensor data. If the query results in the following error, then load external data source definitions, if you have not done so already. Then restart the XRay CEP Servers and Web Server.
com.nastel.jkool.jkql.parser.JKQLUnknownItemTypeException: Error at or near line 1, offset 5, token 'Sensor': Unknown item type 'Sensor'
An example of a jKQL query and error is provided below.