Socket
Socket
Sign inDemoInstall

@opencensus/nodejs-base

Package Overview
Dependencies
25
Maintainers
6
Versions
12
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    @opencensus/nodejs-base

OpenCensus is a toolkit for collecting application performance and behavior data.


Version published
Weekly downloads
5.7K
decreased by-3.96%
Maintainers
6
Install size
1.26 MB
Created
Weekly downloads
 

Changelog

Source

0.1.0 - 2021-07-27

  • chore(stackdriver): upgrade google-auth-library, drop node8 (#887)
  • chore: upgrade gRPC, ts to newest compatible version (#907) BREAKING CHANGE: upgrade to TypeScript 3.x
  • chore(deps): pin googleapis, lock file maintenance (#928)

Readme

Source

OpenCensus for Node.js Base

Gitter chat

OpenCensus Node.js Base is an implementation of OpenCensus, a toolkit for collecting application performance and behavior monitoring data.

The library is in alpha stage and the API is subject to change.

Please join gitter for help or feedback on this project.

Installation

Install OpenCensus Base with:

npm install @opencensus/nodejs-base

Traces

Automatically Instrumenting an Application

For automatic insturmentation see the @opencensus/nodejs package.

Manually Instrumenting an Application

With @opencensus/nodejs-base you have a full control over instrumentation and span creation. The base package doesn't load Continuation Local Storage (CLS) or any instrumentation plugin by default.

const rootSpanOptions = { name: 'your root span' };
tracing.tracer.startRootSpan(rootSpanOptions, (rootSpan) => {

    // You can create as many child spans as needed
    childSpan = tracing.tracer.startChildSpan({
        name: 'name of your child span'
    });
    // Do some operation...
    // Finish the child span at the end of it's operation
    childSpan.end();

    // Finish the root span at the end of the operation
    rootSpan.end();
});

Tracing Options

See the @opencensus/nodejs package for the full API documentation.

Keywords

FAQs

Last updated on 27 Jul 2021

Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc