how to writing own database driver?


  • yeah. i care . thank you


  • So I thought I found a wiki or forum post talking more about database drivers for NodeBB but I can't seem to find it anymore. Specifically, I'm interested in writing something for Couchbase.


  • @djensen47 I personally think we should all strive after a SSDB adapter. As it combines the performance of Redis and persistance of MongoDB ­čśë


  • @AOKP said:

    @djensen47 I personally think we should all strive after a SSDB adapter. As it combines the performance of Redis and persistance of MongoDB ­čśë

    I haven't seen SSDB in the wild and it's probably best to support mainstream drivers to begin with. Redis, MongoDB, and Couchbase (which is CouchDB + Memcache) are some of the most popular NoSQL solutions. I would argue however, that it is a gamble running Redis without HA and redundancy. It's quite easy to lose your entire database running a single instance of Redis.

  • Community Rep

    @djensen47 said:

    It's quite easy to lose your entire database running a single instance of Redis.

    Are you talking about that time when a few members were losing their entire forum? That was already determined to be because the db was exposed to the world and some bad actor was flushing their db remotely. The main downside of redis is that the entire db is held in memory (but is still persisted on disk) so if the DB is large it will take a lot of memory.

  • Gamers

    @BDHarrington7

    User does not exist ­čśĹ

    Our DB got dumped atleast five times. Switched to Mongo; no issues. It was a dev server, so we just copied out the important data by hand, cough need converter cough, to mongo and just put redis to bed. Couchbase is certainly worth a look. Think I read something about work on GPU-accelerated couchdb version... cant seem to find it now.

  • Community Rep

    @bitspook did you guys do a post-mortem?


  • @bitspook why not try Edis then?
    It is a drop in replacement for Redis.

    @djensen47, SSDB is pretty popular in asia and even used for big applications (see clients).

  • Gamers

    @BDHarrington7

    we did not. which program/command is used to do so?

    @AOKP

    we had planned on switching to mongo in the production environment anyway.

  • Community Rep

    @bitspook a post-mortem is just a look at why something failed after the fact, an attempt to understand what happened and ways to prevent it. I was asking to see if you had determined a similar cause, by having your redis database exposed to the world.

  • Gamers

    Ah, nope. Thought you had a diagnostic tool to recommend. Our server guy just said it was flushed and that we needed to move away; "redis isnt built for that, we simply cant run it in production when mongo is compatible."

    Although you can rig redis to work, mongo is better for the usecase. We will need the flexibility with non-standard extensions we will be using.

Suggested Topics

| |