I've made a simple test
Node node = NodeBuilder.nodeBuilder().node();
Client client = node.client();
InputStream mongo =
getClass().getClassLoader().getResourceAsStream("mongodb-river.json");
byte input = IOUtils.toByteArray(mongo);
node.client().prepareIndex("_river", "db",
"_meta").setSource(input).execute().actionGet();
and the river starts but I got a:
Exception in thread "elasticsearch[Jessica Jones]mongodb_river_slurper-
pool-20-thread-1" java.lang.IllegalStateException: can't call
authenticate twice on the same DBObject
at com.mongodb.DB.authenticate(DB.java:430)
at org.elasticsearch.river.mongodb.MongoDBRiver
$Tailer.run(MongoDBRiver.java:269)
That is reasonable.
Noe that I've a test in place (*) I can work on the river to make it
work, and also make some refactoring.
I'm on the aparo fork now. I could create mine but I'm not that
familiar with git, what's your opinion?
Also, I'm not familiar with gradle. I created in less then a minute a
basic pom that allows me to work nicely with the mongodb river and
using es 0.17 snapshot as dep and to get all along nicely in Eclipse.
That's all I need to make it work and I'll not have the time to make
it work also with gradle (changing dependencies, dealing with the
horrible Eclipse integration and generally dealing with gradle... ).
On May 26, 11:33 pm, ildella ilde...@gmail.com wrote:
Hi. I'm also interested in mongo-esintegration. I was wondering today I to
do that and a trigger system at the mongo level seems the most natural way.
There's an open issue, not scheduled yet, here:https://jira.mongodb.org/browse/SERVER-124
I had a look at the code and it seems to me a batch process that wakes up,
check for the last mongo id that's been indexed onESand then index all the
new stored object that he can found on the mongo database, based on the last
id just retrieved.
Anyone used the plugin? I do not have many experience onESso I think that
to try I should
- build it (ok...)
- copy the built jar and the mongo java jar under $ES/plugins/river-mongodb
- configure something accordingly, probably the elasticsearch.yml with a
"mongo" section and all the needed parameter.
- nothing more? probably not... I'll try tomorrow
I'd like to explore the possibility to make this multi-index and
multi-collection of course.
Back to a more deep mongointegration, I think that the only good way is
some trigger in mongo like the one discussed in that jira issue, what do you
think?
--
View this message in context:http://elasticsearch-users.115913.n3.nabble.com/ES-and-MongoDB-integr...
Sent from the Elasticsearch Users mailing list archive at Nabble.com.