I have a MongoDB database which is of relatively low importance. I shovel data from home automation stuff into it (mostly sensor data, sunlight, switch states and so on) and don't need any replication.
I want to subscribe to change streams on that DB, and for that they must be members of a replica set. Is it OK to just add the
--replSet [name] flag to the already existing server and then call
rs.initiate() in it without
rs.add()-ing any secondary members?
What drawbacks will this have (database size, performance, ...)?
Basically I want devices/software to insert data directly into the database, and then have some middleware watching on change streams to then publish the data via RabbitMQ.
Currently I'm inserting into RabbitMQ and MongoDB in parallel. Inserting into RabbitMQ and having a middleware insert the data into MongoDB is also an option, but I want to check both ways of doing it.
I'm not that much of a friend of replica sets as I have an important Database which holds about 80-90MB of documents (total size when exporting all collections to disc), but each member consumes around 1.5 GB of space (
--logpath data excluded).