Hi,
This question is related to SolrJ document as a bean. I have an entity
that has another entity within it. Could you please tell me how to annotate
for inner entities? The issue I am facing is the inner entities fields are
missing while indexing. In the below example, It is just adding Content
fields and missing out author name and id.
Example: "Content" is one class that has "Author" as its has-a
relationship entity.
class Content{
@Field("uniqueId")
String id;
@Field("timeStamp")
Long timeStamp;
//What should be the annotation type for this entity?
Author author;
}
class Author{
@Field("authorName")
String authorName;
@Field("authorId")
String id;
}
My schema xml is:
<field name="uniqueId" type="string" />
<field name="timeStamp" type="long" />
<field name="authorName" type="string" />
<field name="authorId" type="string" />
Thank you. - David