const collection = connection.collection('feeds');
const changeStream = collection.watch();
changeStream.on('change', event => {})
const filter = [{
$match: {
'fullDocument.username': 'marvel',
$and: [
{operationType: 'insert'}
]
}
}];
const options = {fullDocument: 'updateLookup'};
const changeStream = await collection.watch(filter, options);
changeStream.on('change', next => {
socket.emit('messages', [next.fullDocument])
});