mercredi 29 juin 2016

Elasticsearch Nested Indexing using Pentaho Data Integration

I need your help. I have problem indexing my data to elasticsearch type nested from mysql. To do indexing to elastic search type nested I must have object data. I have been used modified javascript value to modify data to object. But, it doesn’t work cause it doesn’t support type object in output fields. I have posts and comments table which posts is parent and comments is child. I need to transform posts and comments like this:

{ "id" : "3", “title”:”blablabla”, “description” : “this is description of blablabla“, "publish_at":"1457230597", “comments” : [ { “id” : "1", “post_id” : "3", “user_id” : "3", “comment” : “this is comment 1”, }, { “id” : "1", “post_id” : “3”, “user_id” : “5”, “comment” : “this is comment 2”, } ] }

This is just sample, so please ignore about name field and content. I already read about data type supported in pentaho. But none support to object. I believe still there is one step that I don't know yet. Any recommendation what should I do?

Aucun commentaire:

Enregistrer un commentaire