Replication for using Change Streams

To use change streams we need to use mongoDB in replica set mode. But currently we don’t need replication, but still need to use change streams. Would there be any problem if we create a replica set with one primary and one arbiter only, which will not cause any replication. Or Is there a way to do it without replication?

You may simply start a single mongod instance with replica set option and you will be able to use change stream.

You do not need an arbiter to do that.

Is there any negative impact of using mongodb in replica mode without any replicas ?

1 - you do not have redundancy compared to running with 3 nodes
2 - need extra RAM and disk space for the oplog
3 - need extra CPU for updating the oplog

But to

you have no choice but to run with replica set.

@at_11, please followup on your thread.

Do you have any other question?

If not please provide closure by marking one of the post as the solution.

Thanks in advance