Socket
Socket
Sign inDemoInstall

agentkeepalive

Package Overview
Dependencies
Maintainers
4
Versions
49
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

agentkeepalive - npm Package Compare versions

Comparing version 4.1.0 to 4.1.1

9

History.md
4.1.1 / 2020-04-25
==================
**fixes**
* [[`bbd20c0`](http://github.com/node-modules/agentkeepalive/commit/bbd20c03b8cf7dfb00b3aad1ada26d4ab90d2d6e)] - fix: definition error (#87) (吖猩 <<whxaxes@qq.com>>)
**others**
* [[`3b01699`](http://github.com/node-modules/agentkeepalive/commit/3b01699b8e90022d5f56898dd709e4fe7ee7cdaa)] - test: run test on node 12 (#84) (Igor Savin <<iselwin@gmail.com>>)
4.1.0 / 2019-10-12

@@ -3,0 +12,0 @@ ==================

70

index.d.ts

@@ -1,18 +0,42 @@

declare module "agentkeepalive" {
import * as http from 'http';
import * as https from 'https';
import * as http from 'http';
import * as https from 'https';
interface PlainObject {
[key: string]: any;
}
declare class HttpAgent extends http.Agent {
constructor(opts?: AgentKeepAlive.HttpOptions);
readonly statusChanged: boolean;
createSocket(req: http.IncomingMessage, options: http.RequestOptions, cb: Function): void;
getCurrentStatus(): AgentKeepAlive.AgentStatus;
}
interface Constants {
CURRENT_ID: Symbol;
CREATE_ID: Symbol;
INIT_SOCKET: Symbol;
CREATE_HTTPS_CONNECTION: Symbol;
SOCKET_CREATED_TIME: Symbol;
SOCKET_NAME: Symbol;
SOCKET_REQUEST_COUNT: Symbol;
SOCKET_REQUEST_FINISHED_COUNT: Symbol;
}
declare class AgentKeepAlive extends HttpAgent {}
declare namespace AgentKeepAlive {
export interface AgentStatus {
createSocketCount: number,
createSocketErrorCount: number,
closeSocketCount: number,
errorSocketCount: number,
timeoutSocketCount: number,
requestCount: number,
freeSockets: object,
sockets: object,
requests: object,
createSocketCount: number;
createSocketErrorCount: number;
closeSocketCount: number;
errorSocketCount: number;
timeoutSocketCount: number;
requestCount: number;
freeSockets: PlainObject;
sockets: PlainObject;
requests: PlainObject;
}
export interface HttpOptions extends http.AgentOptions {
interface CommonHttpOption {
keepAlive?: boolean;

@@ -25,11 +49,6 @@ freeSocketTimeout?: number;

export interface HttpsOptions extends https.AgentOptions {
keepAlive?: boolean;
freeSocketTimeout?: number;
freeSocketKeepAliveTimeout?: number;
timeout?: number;
socketActiveTTL?: number;
}
export interface HttpOptions extends http.AgentOptions, CommonHttpOption { }
export interface HttpsOptions extends https.AgentOptions, CommonHttpOption { }
export default class HttpAgent extends http.Agent {
export class HttpsAgent extends https.Agent {
constructor(opts?: HttpOptions);

@@ -41,8 +60,5 @@ readonly statusChanged: boolean;

export class HttpsAgent extends https.Agent {
constructor(opts?: HttpsOptions);
readonly statusChanged: boolean;
createSocket(req: http.IncomingMessage, options: https.RequestOptions, cb: Function): void;
getCurrentStatus(): AgentStatus;
}
export const constants: Constants;
}
export = AgentKeepAlive;
{
"name": "agentkeepalive",
"version": "4.1.0",
"version": "4.1.1",
"description": "Missing keepalive http.Agent",

@@ -44,2 +44,3 @@ "main": "index.js",

"autod": "^3.0.1",
"coffee": "^5.3.0",
"egg-bin": "^4.9.0",

@@ -50,3 +51,4 @@ "egg-ci": "^1.10.0",

"mm": "^2.4.1",
"pedding": "^1.1.0"
"pedding": "^1.1.0",
"typescript": "^3.8.3"
},

@@ -57,3 +59,3 @@ "engines": {

"ci": {
"version": "8, 10"
"version": "8, 10, 12"
},

@@ -60,0 +62,0 @@ "author": "fengmk2 <fengmk2@gmail.com> (https://fengmk2.com)",

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