kinesalite

A mock implementation of Amazon's Kinesis built on LevelDB

npm install kinesalite
13 downloads in the last week
22 downloads in the last month

Kinesalite (formerly kinesis-mock)

Build Status

A mock implementation of Amazon's Kinesis, focussed on correctness and performance, and built on LevelDB (well, @rvagg's awesome LevelUP to be precise).

The Kinesis equivalent of dynalite.

To read and write from Kinesis streams in Node.js, consider using the kinesis module.

Example

$ kinesalite --help

Usage: kinesalite [--port <port>] [--path <path>] [options]

A mock Kinesis http server, optionally backed by LevelDB

Options:
--help                 Display this help message and exit
--port <port>          The port to listen on (default: 4567)
--path <path>          The path to use for the LevelDB store (in-memory by default)
--createStreamMs <ms>  Amount of time streams stay in CREATING state (default: 500)
--deleteStreamMs <ms>  Amount of time streams stay in DELETING state (default: 500)
--updateStreamMs <ms>  Amount of time streams stay in UPDATING state (default: 500)

Report bugs at github.com/mhart/kinesalite/issues

Or programmatically:

// Returns a standard Node.js HTTP server
var kinesalite = require('kinesalite'),
    kinesaliteServer = kinesalite({path: './mydb', createStreamMs: 50})

// Listen on port 4567
kinesaliteServer.listen(4567, function(err) {
  if (err) throw err
  console.log('Kinesalite started on port 4567')
})

Installation

With npm do:

$ npm install -g kinesalite

Done

  • All validations
  • CreateStream
  • DeleteStream
  • DescribeStream
  • ListStreams

TODO

  • GetRecords
  • GetShardIterator
  • PutRecord
  • MergeShards
  • SplitShard
npm loves you