Skip to content

telemetry-js/publisher-appoptics

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

publisher-appoptics

Publish single or summary metrics to AppOptics.
A telemetry plugin.

npm status node Test JavaScript Style Guide

Table of Contents

Click to expand

Usage

With Telemetry

const telemetry = require('@telemetry-js/telemetry')()
const appoptics = require('@telemetry-js/publisher-appoptics')

telemetry.task()
  .publish(appoptics, { token: 'XX' })

If an HTTP request to AppOptics fails, it is retried. If it fails 5 times, an error event will be emitted and in this case forwarded to telemetry:

telemetry.on('error', (err) => {
  console.error(err)
})

Standalone

Yet to document.

const appoptics = require('@telemetry-js/publisher-appoptics')

API

Options

Yet to document.

Install

With npm do:

npm install @telemetry-js/publisher-appoptics

Acknowledgements

This project is kindly sponsored by Reason Cybersecurity Ltd.

reason logo

License

MIT © Vincent Weevers