Elasticsearch has a plug-in module called River that can import data from an external data source into a elasticsearch and index it. The river is a singleton pattern on the cluster, it is automatically assigned to a node, and when the node is hung, the river is automatically assigned to another node. Currently supported data sources include: Wikipedia, MongoDB, CouchDB, RabbitMQ, RSS, Sofa, JDBC, Filesystem,dropbox, etc. River has a number of specified specifications that can be used to develop plug-ins suitable for their own application data.
1, the installation of MongoDB River:https://github.com/richardwilly98/elasticsearch-river-mongodb, http://blog.csdn.net/huwei2003 /article/details/40407555
git clone https://github.com/richardwilly98/elasticsearch-river-mongodb.gitCD elasticsearch-river-MongoDB
git tag
git checkout elasticsearch-river-mongodb-2.0.5
MVN CLEANMVN COMPILEMVN Package
Vim install-local.sh --Change the plugin--remove to plugin remove; Comment out the last line of the sudo command because there is no URL parameter for the plugin command.
./install-local.sh
CD target/releases/
Linux installation Elasticsearch and MongoDB distributed cluster environment data synchronization