{"library":"poolee","title":"poolee","description":"HTTP pool and load balancer for Node.js (v1.0.1, stable). Provides connection pooling, load balancing across multiple endpoints, automatic retries with exponential backoff, health checks via ping endpoints, and configurable timeouts. Differentiators: simple API, built-in retry filtering, and endpoint health management. Last release in 2017; maintenance mode.","language":"javascript","status":"maintenance","last_verified":"Sat Apr 25","install":{"commands":["npm install poolee"],"cli":null},"imports":["const Pool = require('poolee')","const { Pool } = require('poolee')","pool.request(options, body, callback)"],"auth":{"required":false,"env_vars":[]},"quickstart":{"code":"const Pool = require('poolee');\nconst http = require('http');\n\nconst servers = [\n  '127.0.0.1:8886',\n  '127.0.0.1:8887',\n  '127.0.0.1:8888',\n  '127.0.0.1:8889'\n];\n\nconst pool = new Pool(http, servers, {\n  maxPending: 1000,\n  maxSockets: 20,\n  timeout: 60000,\n  resolution: 1000,\n  keepAlive: true,\n  ping: '/health',\n  pingTimeout: 2000,\n  retryFilter: function(options, response, body) {\n    return response.statusCode === 500;\n  },\n  retryDelay: 20,\n  maxRetries: 3\n});\n\npool.request(\n  { method: 'GET', path: '/api/data' },\n  null,\n  function(error, response, body) {\n    if (error) {\n      console.error(error.message);\n      return;\n    }\n    console.log(response.statusCode, body);\n  }\n);","lang":"javascript","description":"Creates a pool with multiple servers, configures options including health checks and retry filter, then makes a GET request.","tag":null,"tag_description":null,"last_tested":null,"results":[]},"compatibility":null}