This is documentation for the old, first-generation Kaa platform v0.x.
Next generation Kaa Enterprise IoT platform is now available! Try it free with a 30-days trial.
Kaa Enterprise documentation is here.
. . .

Building Kaa server from source code

This section describes how to build the Kaa server from the source code available on GitHub.

Before building the Kaa server from source, make sure that Oracle JDK 8 and Apache Maven are installed on your machine.

Fetching source code

You can use any Git client to fetch Kaa source code from the repository.

To download Kaa repository, run the command below.

$ git clone https://github.com/kaaproject/kaa.git

To build Kaa node Debian/RPM packages, change the current directory after cloning.

cd kaa

And run the following command.

$ mvn -P compile-gwt,mongo-dao,mariadb-dao clean install verify
$ mvn -P compile-gwt,mongo-dao,mariadb-dao,build-rpm clean install verify

The Debian build will work correctly on both Linux and Windows operation systems, while the RPM build will only work on Linux with the RPM package manager installed.

For the mvn command, the build number and git commit variables are set to emulate Jenkins build variables that are substituted automatically on the build machine.

Add the -DskipTests suffix to the mvn command to skip execution of tests and speed up the build process.

Available Maven profiles

Maven profile Description
build-rpm As implied in the profile name, it will force to generate .rpm packages. This is useful if you are going to install Kaa on RPM-based Linux distribution (Red Hat Linux, Oracle Linux, etc.).
cassandra Compiles Cassandra log appender.
cassandra-dao Forces Kaa to use Cassandra NoSQL storage. If none is set, MongoDB used by default.
compile-client-c Compiles endpoint C SDK and runs tests.
compile-client-cpp Compiles endpoint C++ SDK and runs tests.
compile-client-objc Compiles endpoint Objective-C SDK and executes tests. Compiling only possible on OS X and CentOS operation systems.
compile-gwt Compiles Administration UI. Can be skipped during regular builds.
compile-thrift Forces Thrift compiler to generate code from Thrift files.
couchbase Compiles Couchbase log appender.
jenkins Forces Kaa to run integration tests.
kafka Compiles Kafka log appender.
license Forces Kaa to use Maven License plugin.
mariadb-dao Forces Kaa to use MariaDB SQL storage. Enabled by default.
mongo-dao Forces Kaa to use MongoDB NoSQL storage. Enabled by default.
oracle-nosql Compiles Oracle NoSQL log appender.
postgresql-dao Forces Kaa to use PostgreSQL SQL storage. If none is set, MariaDB used by default.

NOTE: compile-client-* profiles are optional. All endpoint SDKs will be available in Kaa node by default. This profiles are used only for verification of endpoint SDK build during development.

Build artifacts

You can use the following command to browse the Kaa node build artifacts in case of successful build.

$ ls server/node/target/kaa-node.deb
$ ls server/node/target/rpm/kaa-node/RPMS/noarch/kaa-node*.rpm

Installing Kaa

After you successfully built the Kaa server from sources, install a Kaa single node as described in Single node installation.