Code Monkey home page Code Monkey logo

node-redis-connection-pool's Introduction

npm version Build Status Coverage Status Patreon donate button

node-redis-connection-pool See on Github

Simplistic node redis connection pool ready can scale with generic-pool support

Documentation

Prerequisites

  • node >= 8 This module requires nodejs v8 or later
  • redis >= 4 This module requires redis v4 or above as it has dependencies on UNLINK and redis.replicate_commands() for pattern deletion.

Getting started

    npm install node-redis-connection-pool

Usage

  • Seemless execution of commands.
    var RedisPool = require("node-redis-connection-pool");
    var pool = new RedisPool();

    pool.sendCommand("set", ["key", "value"])
  • Want redis raw connection? you got it
    pool.acquire()
      .then(conn => {

        // Do some work

        // At the end release the conn back to the pool
        pool.release(conn)
      });

API

  • RedisPool([options])
options object properties
Name Type Description
name string

Name your pool

redisOptions object

opts from node_redis#options-object-properties

poolOptions object

opts from node-pool#createpool

logger object

Inject your custom logger

Run tests

bash test.sh

Contribute

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

Backers

Maintainers

These amazing people are maintaining this project:

Sponsors

No sponsors yet! Will you be the first?

Patreon donate button Flattr donate button

Contributors

These amazing people have contributed to/reviewed this project:

Discover how you can contribute by heading on over to the CONTRIBUTING.md file.

node-redis-connection-pool's People

Contributors

pasupulaphani avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

Forkers

sonvt1710 ade1705

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.