Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

cat-nodejs

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

cat-nodejs

Pure nodejs client for cat

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Maintainers
1
Created
Source

cat.js

  • Version: 0.0.1
  • Author: cdchu@ctrip.com

Install

npm install cat-nodejs

Usage

  1. create app.config.js as nodejs module format

      module.exports={
      	'AppID':'921821',
      	'CatServer.Config.Url':'http://10.0.0.1/catconfig',
     	'CatServer':['10.0.0.1:1234','10.0.0.2:1234']
      };
    
  2. require ctriputil

     var cat=require('cat-nodejs');
    

CAT APIs

  • Method spanInstance cat.span(type,name,data)
    • type as string
    • name as string
    • data as string or number or array or object
  • Method self cat.event(type,name,data)
    • type as string
    • name as string
    • data as string or number or array or object
  • Method self cat.error(message,stack)
    • message as string or error
    • stack as string
  • Method self CtripUtil.cat.http(server)
    • server as httpServerInstance
  • Class spanInstance
    • Method spanInstance spanInstance.span(type,name,data)
      • type as string
      • name as string
      • data as string or number or array or object
    • Method self spanInstance.event(type,name,data)
      • type as string
      • name as string
      • data as string or number or array or object
    • Method self spanInstance.error(message,stack)
      • message as string or error
      • stack as string
    • Method parent spanInstance.end()
      • parent as spanInstance or cat

FAQs

Package last updated on 01 Dec 2016

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