Related pages:

Your Rating:
Results:
PatheticBadOKGoodOutstanding!
20 rates

Follow the steps below to get your EUM App Key and instrument your Cordova-based apps.

For native mobile applications, following either the iOS Instrumentation or Android Instrumentation instructions. The Mobile Agents will inject the JavaScript Agent and auto-instrument your mobile application including the auto-instrumentation of the UIWebView/WebView.

Check Requirements

To use the AppDynamics Cordova plugin, your hybrid application must be using the following:

  • Cordova 8.0.0+
  • npm 3.10.10+
  • Node.js v6.11.3+

Get Your Application Key

After you completed the Getting Started Wizard, you were given an EUM App Key. You will need this key when you modify the source code. In some cases, multiple mobile applications can share the same key.

If you have completed the Getting Started Wizard, but don't have your EUM App Key, see Get Your Application Key.

Install and Initialize the Cordova Plugin

The AppDynamics Cordova plugin is certified to work with the Ionic and PhoneGap frameworks. Thus, the installation instructions below are for Ionic and PhoneGap applications. You should also be able to use the plugin for other Cordova-based frameworks. See the plugin installation instructions for your Cordova-based framework.

Ionic

From the root directory of your Ionic application, run the following commands to install the plugin and build the mobile app. See the Ionic Cordova plugin documentation for more information.

  1. Replace the values in brackets with the configurations for your app and run the command to add the configured plugin.
    For SaaS deployments:

    ionic cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6]  --save

    For on-prem deployments, replace the value for the variable COLLECTOR_URL with the URL to your EUM Server and the value for SCREENSHOT_URL with the URL to your on-prem Screenshot Service.

    ionic cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --variable COLLECTOR_URL="http(s)://<on-prem_eum-server_url>" --variable SCREENSHOT_URL="http(s)://<on-prem_screenshot_service-url>" --save
  2. (Optional) You can also set variables to disable user interaction capture mode (iOS/Android) and set the URL to test the network connectivity of Cordova iOS applications.

    1. The interaction capture mode is on by default, but you can disable it by setting the variable INTERACTION_CAPTURE_MODE to false:

      ionic cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable INTERACTION_CAPTURE_MODE=false --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --variable COLLECTOR_URL="http(s)://<on-prem_eum-server_url>" --variable SCREENSHOT_URL="http(s)://<on-prem_screenshot_service-url>" --save
    2. By default, the Cordova Plugin will use http://google.com to test the connectivity of Cordova iOS applications You can, however, use a different URL to test the connectivity by setting the variable REACHABILITY_HOST to the URL. In the example below, the Cordova Plugin is configured to use http://example.com to test the connectivity of the Cordova iOS application.

      ionic cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable REACHABILITY_HOST=http://example.com --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --save
  3. Build the mobile app:

    ionic cordova build [android, ios]

PhoneGap

From the root directory of your PhoneGap application, run the commands below to install the plugin. See the PhoneGap plugin documentation for more information.

  1. Replace the values in brackets with the configurations for your app and run the command to add the configured plugin.
    For SaaS deployments:

    phonegap cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --save

    For on-prem deployments, replace the value for the variable COLLECTOR_URL with the URL to your EUM Server and the value for SCREENSHOT_URL with the URL to your on-prem Screenshot Service.

    phonegap cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --variable COLLECTOR_URL="http(s)://<on-prem_eum-server_url>" --variable SCREENSHOT_URL="http(s)://<on-prem_screenshot_service-url>" --save
  2. (Optional) You can also set variables to enable user interaction capture mode (iOS/Android) and troubleshoot the network connectivity of Cordova iOS applications.

    1. To view the UI events triggered by user interactions in sessions, set the variable INTERACTION_CAPTURE_MODE to true:

      phonegap cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable INTERACTION_CAPTURE_MODE=true --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --save
    2. To test the network connectivity of Cordova iOS applications, set the variable REACHABILITY_HOST to TBD:

      phonegap cordova plugin add appd-plugin-eum-mobile --variable APP_KEY="<#EUM_APP_KEY#>" --variable REACHABILITY_HOST=TBD --variable SCREENSHOTS_ENABLED=<true|false> --variable LOGGING_LEVEL=[0-6] --save
  3. Build the mobile app:

    phonegap cordova build [android, ios]

Customize the Cordova Application Instrumentation

See Customize the Cordova Application showing how to use the Cordova SDK through examples and brief explanations.

  • No labels

3 Comments

  1. appd-plugin-eum-mobile
    this should be the path to the plugin, not the name
  2. ,
    this is probably better represented as android
  3. appd-plugin-eum-mobile
    it should be path to the plugin location