Skip to content

Integrate New Apps with Radar Platform

Yatharth Ranjan edited this page Nov 17, 2017 · 24 revisions

Integrate New Apps with Radar Platform

The Radar platform is a healthcare pipeline to obtain clinical and health data from various active and passive sources like questionnaires, wearable devices, phone sensors, etc. The platform is open source and is based on top of apache kafka ADD URL and is built as such to accommodate easy integration of future devices and applications to the platform. The main components of the system that will be required for integration of new devices are-

  1. Management Portal ADD URL - This is the central management service of the Radar Platform. It offers services like authorization of different components, Creating and storing info of Subjects, Sources, Studies( or Projects),etc, Creating relationship between different components (like registering a source to a subject), etc.
  2. Rest Proxy ADD URL - Since the platform is based on Apache Kafka ADD URL, we can either send data directly into kafka via a producer or use a rest proxy. This is for sending data into kafka topics through a RESTful interface. This a confluent provided product so we can post data using http requests.
  3. Schema Registry ADD URL - The data we send into the platform from our app or device will be converted to [AVRO ADD URL] format before going into kafka topics. For converting our data to avro, Rest proxy needs to know the schema (or format) of the data we are sending. These schemas are stored in the schema registry so that we don't have to send them with each request as this increases the latency.

Step 1: Get the Access Token from the Management Portal

1. Get Token by scanning the QR code

2. Get Token by using client credentials

Step 2: Register your device or App as a source to a Subject

Step 3: Get the schema version for the Topic

1. Get versions of the schema

2. Get the id of the latest version of the schema

Step 4: Post data to the Platform

1. Add the access token to the request header

2. Create request body

3. Post the record to kafka

Step 5: Additional enhancements

Get the latest schema periodically

Refresh the token before it expires

Use OAuth client libraries if Java and client credentials grant type