Parent-Child mapping using JAVA client API using POJO's

Hi, I am a newbie working with ElasticSearch. I have been working on an application for which I would like to use ES as the backend datastore. I have POJO's or domain entities for which I would like to create a Parent-Child relation. I am using the ObjectMapper java API to serialize and deserialize the objects as json to the ES datastore. I am looking for any examples which can get me started on this. Your help is very important as well as appreciated.

Why do you think you need parent/child implementation? That might not be the case.

Look for example this: Book search, Parent & child mapping multiple author

Hi David,

Let me give you more details by an example. Let's say we have a blog post by an author but an author can have multiple blog posts. So, I would like to use the author as one index and the corresponding posts as another index. Since an author related fields may not be changed or updated very often but on the other hand the posts get added, updated very often.

Index only blog posts in that case.
Reindex the blog posts if your author change.

In such a usecase, you will may be reindex at most 1000 docs which is nothing.

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.