Building Pulse
Building the project
sbt is used for building scala, and Make is added as a wrapper to simplify building tasks.
Makefile targets are run with make <target-name>
, full documentation can be found in the Makefile:
dist
: create a distribution (parcel and csd)test
: run all testspackage
: create jars from source. This will place all jars in thetarget/lib
directorinstall
: install parcel and CSD. This is only valid on a node running Cloudera Manager and will install the csd/parcel to /opt/cloudera/csd and /opt/cloudera/parcel-repo. It will not distribute/activate the parcel or refresh/install the CSD in Cloudera Manager
Before submitting a pull request, please make sure make test
and make dist
both pass successfully.
Environment Variables
When building the project two environment variables are needed: - CDH_VERSION: can be one of 5 or 6. This controls the solr version for building/testing as well as the name of the parcel and csd files - VERSION: The version of Pulse being built
CSD
The CSD (Custom Service Descriptor) allows Cloudera Manager to easily manage and monitor the Pulse log aggregation framework, creating 'roles' for each of the Alerting Engine, Collection Roller, and Log Collector.
Building the CSD
$ make
Installing the CSD
This is for a local/development installation only, see instalation for production installation instructions.
This will copy the CSD to /opt/cloudera/csd. You must be on the Cloudera Manager node
sudo make install
Refresh the CSD list
GET /cmf/csd/refresh
Uninstall any old CSD
GET /cmf/csd/uninstall?csdName=PULSE-0.1.0
Install the CSD
GET /cmf/csd/install?csdName=PULSE-0.1.1
Cloudera Parcel
Building the parcel
At the root of the project, run
$ make package
This will collect all dependent jars into the lib_managed
folder
Then from this directory run:
$ make
Installing the Parcel
This will copy the CSD to /opt/cloudera/csd. You must be on the Cloudera Manager node
sudo make install
Distributions
To build a distribution make sure you set the VERSION
and CDH_VERSION
env variables, then
```$xslt export VERSION=2.1.2 export CDH_VERSION=5 make clean dist
```
Output will be in the dist6/
or dist5
folder depending on which CDH version you built for.