I think I already know what the answer to this question will be but I have a use case where I have a collection of Users and a collection of QuestionOverviews. I am using Morphia to map POJOS to the documents within these collections.
My wish is that when Morphia maps a User object it also fills a set of all the QuestionOverviews for that particular user. If i was using Hibernate I could just have a one-to-many annotation and hibernate would do the rest.
Am i able to do something similar with Morphia? I thought that might be what @embedded is for but I have now found out I am mistaken.
No you are right you have to use @Embedded only for more reference click here