New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

connect-settimeout

Package Overview
Dependencies
Maintainers
2
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

connect-settimeout

a connect middleware that runs a provided function if a request lasts longer than a given duration

  • 0.0.3
  • latest
  • Source
  • npm
  • Socket score

Version published
Weekly downloads
4
decreased by-55.56%
Maintainers
2
Weekly downloads
 
Created
Source

connect-settimeout

a connect middleware that runs a provided function if a request lasts longer than a given duration

Build Status Coverage Status

NPM

Setup:

Add this middleware to your connect or express app like this:

var connectSetTimeout = require('connect-settimeout');
app.use(connectSetTimeout(function(req, res){
  // do whatever you want with the slow request, eg:
  console.error("There was a slow response at ", req.method, req.url);
}, 10000));  // 10 seconds, specified in milliseconds

Keywords

FAQs

Package last updated on 29 Aug 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