Socket
Socket
Sign inDemoInstall

node-proxy-latency-tester

Package Overview
Dependencies
13
Maintainers
1
Versions
1
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

    node-proxy-latency-tester

Node proxy for simulating webserver latencies on localhost or testing enviroments (CI)


Version published
Weekly downloads
3
Maintainers
1
Install size
252 kB
Created
Weekly downloads
 

Readme

Source

Node Poxy Latency Tester

This command line tool helps you to create a proxy that adds adds a latency between two services. This is useful for testing purposes and simulations.

Installation

via npm:

npm install node-proxy-latency-tester

Usage

$ node-proxy-latency-tester -h

Usage:
  node-proxy-latency-tester [OPTIONS] [ARGS]

Options:
  -t, --target [NUMBER]  target port (service port) (Default is 8080)
  -f, --forward [NUMBER] forward port (new port through proxy) (Default is 7070)
  -l, --latency [NUMBER] latency in ms (Default is 0)
  -h, --help             Display help and usage details

Let's say that you have a service running on localhost:8080 and you can add a latency of 300 ms without changing the service. You can easily accomplish this with:

np -t 8080 -f 8081 -l 300

Now you can use your service on port 8081 with a latency of 300 ms. You can also use np for short.

Keywords

FAQs

Last updated on 21 Mar 2017

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