Socket
Socket
Sign inDemoInstall

@google-cloud/trace-agent

Package Overview
Dependencies
Maintainers
1
Versions
67
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@google-cloud/trace-agent

Node.js Support for StackDriver Trace


Version published
Weekly downloads
112K
increased by5.42%
Maintainers
1
Weekly downloads
 
Created

What is @google-cloud/trace-agent?

@google-cloud/trace-agent is a Node.js client library for Google Cloud Trace, which allows you to automatically collect latency data from your applications and visualize it in the Google Cloud Console. This helps in monitoring and diagnosing performance issues in your applications.

What are @google-cloud/trace-agent's main functionalities?

Automatic Tracing

Automatically traces incoming requests and outgoing HTTP calls, capturing latency data without requiring manual instrumentation.

const tracer = require('@google-cloud/trace-agent').start();

Custom Spans

Allows you to create custom spans to measure the latency of specific sections of your code.

const tracer = require('@google-cloud/trace-agent').start();
const span = tracer.createChildSpan({ name: 'custom-span' });
// Do some work
span.endSpan();

Context Propagation

Ensures that trace context is propagated across asynchronous boundaries, allowing you to get a complete picture of a request's lifecycle.

const tracer = require('@google-cloud/trace-agent').start();
tracer.runInRootSpan({ name: 'root-span' }, rootSpan => {
  // Do some work
  rootSpan.endSpan();
});

Other packages similar to @google-cloud/trace-agent

Keywords

FAQs

Package last updated on 04 Jun 2020

Did you know?

Socket

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
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc