NeDB, a pure Javascript database for Node.js and Node Webkit

  • As someone that has a JS background and is looking to get started with node, this is a welcome addition. I like the idea of being able to throw a require statement in and get up and running. Syntax for inserts and queries look straightforward too. Thanks!

  • The trend continues where all things eventually get implemented in Javascript. Waiting for JS.js

  • Great idea and project. Questions: a) Is the database loosely coupled to query language implementation? b) In my biased opinion RethinkDB has a much better query language. Is there a way to implement RethinkDB's query semantics and how much work is involved? c) Underscore.js has a ton of collection manipulation functions. How easy is it to use it from within NeDB? d) How easy/difficult is it to run NeDB as a lightweight RESTful server, in its own Node process?

  • Perfect timing. I spun up a project fairly recently using node-webkit and wanted this, exactly. Getting SQLite integrated wasn't particularly painful, but a document storage model is just what I had hoped for. Thanks for the contribution; looking forward to giving it a try!

  • It might be interesting to persist snapshots to S3. It might be usable for small projects on Heroku/etc with ephemeral storage. It could be patched here (?) [1], but clearly there'd be a lot of issues with the long network call, how often to do it, how durable it really is, etc.

    1: https://github.com/louischatriot/nedb/blob/b1abd34384cefea16...

  • Reminds me of a beefed-up version of this similar project: https://github.com/chjj/node-tiny

  • node-webkit seems to have a number of options for local storage: https://github.com/rogerwang/node-webkit/wiki/Save-persisten...

    Amongst those are a native SQL engine (sqlite) and a native NoSQL engine (levelDB, through the IndexedDB API)

    It'd be useful to know what benefits NeDB brings over other existing storage mechanisms.

  • From what I can make out, this won't work under cluster, right? You won't get new data written from one worker in another. It also has no locking so you can easily corrupt the database if you access it from multiple programs at once (or with cluster).

  • What does this have to do with node-webkit? My understanding is that nodejs is a subset of node-webkit, so by saying "this is for nodejs", you imply "this is for node-webkit".

  • node.js used to see really slow GC cycles (>1s) at over ~5/600MB of heap usage, and bomb out fatally at 1GB. Is this still the case?

    If it is, you should probably put a larger warning about dataset size than the line you currently have :)

  • undefined

  • Nice welcome addition to the node webkit landscape.

  • How do you pronounce "NeDB"?

  • Awesome! I've been looking for a project like this for a small app and have been exploring things like EJDB and UnqLite, among others. I'll definitely be checking this out. Thanks.

  • How is this different from mongodb? Aside from being written in javascript and having a non-existent community around it?