Login - Using a MySQL existing database?

General Discussion

Suggested Topics


  • 1 Votes
    1 Posts
    174 Views

    I'll soon be creating a custom theme and some plugins for a forum that is already in use and I'm thinking about running second instance on beta.forum.url with the new theme and plugins enabled when it's close to being ready (but in need of testing), that I'd like to work with the same database as the main forum - so that users can just use beta if they want to preview new features while still using the same forum as others.

    Now, I know that the list of themes/plugins enabled is stored in database, so I'd probably need to do something about that, but is there anything else that would stop me from running two instances with a bit different configs off one database? Some sync issue with posts/topics or something like that?

    EDIT: actually, since I might as well help others, would it be a good idea to add an option to add some instance identifier to db plugin entries to core? Perhaps in config.json? So that if it's set NodeBB would look for plugins:<instance>:active for example.

  • 0 Votes
    2 Posts
    695 Views

    We use https://github.com/dcodeIO/bcrypt.js to store user passwords.

  • 1 Votes
    7 Posts
    3k Views
  • 0 Votes
    4 Posts
    2k Views

    @belstgut said:

    Not really sure what all the hype about mongodb/redis lately is, if you can use well tested sql databases.

    MongoDB is well tested too. But beyond being super stable, it is screaming fast - far faster than any relational database, it has amazing sharding properties, it speaks native JSON, it is getting a massive amount of active development, it is considered the native database for Node.js on which NodeBB is built and it scales like crazy.

    Now the big one.... when using Node... those "well tested sql databases" are not well tested. MongoDB is far more stable and tested than any of them and, in fact, lack of highly reliable drivers is a major issue for relational (what you call SQL) databases.

    So there are very, very good reasons to use NoSQL, especially MongoDB specifically. Speed, stability, battle tested, native, etc. I'm not actually clear on any upside to using a relational database here. Relationships are nice, but would they add any value at all in an online community infrastructure?

    Also, I should note, some online communities that we have dealt with have scaling issues specifically because they eschewed this advice and went with those "well tested" relational databases. Once they grew and got busy they were unable to keep pace and they bogged down and had to throw crazy amounts of money at keeping respectable performance when MongoDB or other similar datastore could have been faster for cheaper.