Kaa releases
Skip to end of metadata
Go to start of metadata


To implement a custom transport, you need to complete the following steps.

  1. Design and compile a configuration schema.
  2. Implement the TransportConfig interface.
  3. Implement Transport.
  4. Provision the transport in a Bootstrap server and/or an Operations server.

We recommend that you use one of the existing transport implementations as a reference and also review the transports design reference.

Please note that once a new transport is implemented, you will most likely need to implement a corresponding transport channel for one or multiple endpoint SDK platforms. 

Transport configuration schema

A transport configuration schema is an Avro compatible schema that defines configuration parameters for the transport. The following parameters in the schema affect Kaa Admin UI layout.

  • minRowCount - specifies a minimum number of rows in a UI table (If you are using arrays in your schema, you can specify a minimum number of elements in an array with this parameter)
  • displayName - displays the name of the field on UI
  • displayNames - displays the name of each enumeration symbol on UI (only for enumeration fields in the schema)
  • default - displays the default value of the field on UI
  • optional - defines whether the field on UI is optional or mandatory
  • weight - defines a relative width of the corresponding column on UI (only for arrays in the schema)

The following example illustrates a simple transport configuration schema with two fields (host and port).

Once you have prepared your schema, you can compile it using the following command.
java -jar /path/to/avro-tools-1.7.7.jar compile schema <schema file> <destination>
For more information, refer to Compiling the schema. It is also possible to integrate the schema compilation with avro-maven-plugin.

Transport descriptor implementation

Once you have defined and compiled a transport configuration schema, you can proceed to the implementation of a transport descriptor.

A transport descriptor should implement the TransportConfig interface and be annotated with the KaaTransportConfig annotation for the provisioning purposes.

Note: all transport descriptors should be inside the org.kaaproject.kaa.server.transport package or its subpackages.

The following example illustrates a transport descriptor implementation based on the schema defined in the previous section. 


Transport implementation

All transport implementations should implement the Transport interface. We recommend extending AbstractKaaTransport for convenience.

The following example illustrates a transport implementation based on the defined transport configuration schema. 

Transport provisioning

To provision the implemented transport, you need to put all the transport related classes into the classpath of the server. Also, you need to make sure that the transport configuration file is present in the classpath and its schema and name match appropriate parameters from your transport descriptor.

The following example illustrates the configuration file contents that match our transport. This file should be named custom-transport.config.

Note: you can use transport configuration variables from the operations-server.properties or bootstrap-server.properties files; these variables must have the transport prefix.

Copyright © 2014-2015, CyberVision, Inc.

  • No labels