Skip to content
Appdynamics IoT Java SDK to monitor performance of embedded applications on connected devices
Java
Branch: master
Clone or download
Fetching latest commit…
Cannot retrieve the latest commit at this time.
Permalink
Type Name Latest commit message Commit time
Failed to load latest commit information.
config/checkstyle
docs
gradle/wrapper
sample-apps
sdk
.gitignore
LICENSE
NOTICE
README.md
build.gradle
gradle.properties
gradlew
gradlew.bat
settings.gradle

README.md

AppDynamics IoT Java SDK

Table of Contents

Overview

This repository contains the AppDynamics IoT Java SDK that can be used in embedded applications to monitor network perfomance, errors, and business metrics.

What is Included

  • sdk - The Appdynamics Java SDK for IoT.
  • sample-apps - A sample application showing how to use the SDK.
  • docs - The Javadoc for the SDK. It can also be viewed online.

Getting Started

The best way to understand how to use the SDK is to run the sample application.

  1. Clone or download the repo https://github.com/Appdynamics/iot-java-sdk.git in <MY_SOURCE_FOLDER>.

  2. Get an EUM App Key and a Collector URL. Note: If you do not have an AppDynamics account, you can sign up for one here.

  3. Add your EUM app key and Collector URL to your sample app by making the following edits to <MY_SOURCE_FOLDER>/iot-java-sdk/sample-apps/src/main/java/com/appdynamics/iotapps/MyIoTSampleApp.java:

    public static final String APP_KEY = "<YOUR-APP-KEY>";  
    public static final String COLLECTOR_URL = "<YOUR-COLLECTOR-URL>";
  4. Build the sample-app by running the following commands. (It also builds the SDK.)

    cd <MY_SOURCE_FOLDER>/iot-java-sdk
    ./gradlew -p sample-apps clean distTar
  5. Create a new folder where you'll run the deployed code.

    mkdir <MY_DEPLOY_FOLDER>
  6. Copy the distribution tar file that includes the sample app and the AppDynamics IoT Java SDK to this deployment folder.

    cp ./sample-apps/build/distributions/appd-iot-sample-app.tar <MY_DEPLOY_FOLDER>
  7. Un-tar and run the application.

    cd <MY_DEPLOY_FOLDER> 
    tar xvf appd-iot-sample-app.tar  
    ./appd-iot-sample-app/bin/sample-apps
  8. Confirm the IoT Data was reported to the EUM Collector.

Download the Released JAR

The released version of the SDK can be downloaded from https://github.com/Appdynamics/iot-java-sdk/releases.

Build the SDK

  1. Clone or download the repo https://github.com/Appdynamics/iot-java-sdk.git in <MY_SOURCE_FOLDER>.
  2. Make any modifications to the SDK, if desired.
  3. Run the following command from a terminal
    cd <MY_SOURCE_FOLDER>/iot-java-sdk 
    ./gradlew -p sdk/ clean assemble test

Build the Javadocs

  1. Clone or download the repo https://github.com/Appdynamics/iot-java-sdk.git in <MY_SOURCE_FOLDER>.
  2. Make any modifications, if desired.
  3. Run the following command from a terminal
    cd <MY_SOURCE_FOLDER>/iot-java-sdk  
    ./gradlew -p sdk/ clean assemble test generateZippedJavadocs

Documentation

Code Inspection

  • Code Coverage

    The build.gradle file has a task to track code coverage using jacoco

    • Generate the report with the following gradlew command:
      cd <MY_SOURCE_FOLDER>/iot-java-sdk
      ./gradlew test jacocoTestReport
    • View the report by opening the file <MY_SOURCE_FOLDER>/iot-java-sdk/sdk/build/jacocoHtml/index.html in a browser.
  • Code Quality

    The build.gradle file has a task to track code quality using findbugs

    • Generate report with the following gradlew command:
      cd <MY_SOURCE_FOLDER>/iot-java-sdk
      ./gradlew check
    • View the report by opening the files

    <MY_SOURCE_FOLDER>/iot-java-sdk/sdk/build/reports/findbugs/main.html <MY_SOURCE_FOLDER>/iot-java-sdk/sdk/build/reports/findbugs/test.html <MY_SOURCE_FOLDER>/iot-java-sdk/sample-apps/build/reports/findbugs/main.html

  • Coding Standards Inspection The build.gradle file has a task to track code quality using checkstyle

    • Generate the report with the following gradlew command
    cd <MY_SOURCE_FOLDER>/iot-java-sdk
    ./gradlew check
    • View the reports in <MY_SOURCE_FOLDER>/iot-java-sdk/*/build/reports/checkstyle/

Versioning

Versioning of releases of this project is maintained under the Semantic Versioning Guidelines

Copyright and License

The code is released under the Apache 2.0 License. Copyright (c) 2018 AppDynamics LLC and its affiliates.

You can’t perform that action at this time.