Skip to content

Repository files navigation

mongo-utils

A utility for subscribing to a mongo collction for updates whenever there is an insert, update or delete.

	<dependency>
<groupId>org.estonlabs</groupId>
<artifactId>mongo-utils</artifactId>
<version>1.0.0</version>
</dependency>
finalMongoClientmongoClient = newMongoClient("localhost" , 3001 ); finalOplogMonitormongo = newOplogMonitor(mongoClient);
mongo.start();
finalNamespacenamespace = newNamespace( "meteor", "markets" ); //only listen to the insert and delete events. mongo.listenToNameSpace(namespace, this, OplogEventType.INSERT, OplogEventType.DELETE);
//sometime later when finished monitoring callmongo.stop();

About

mongodb utilities

Resources

Stars

1 star

Watchers

1 watching

Forks

Releases

Packages

Contributors

Languages