In @ManyToMany @EmbeddedInDocument, only the list of identifiers (and index/key) are stored in the document. It makes sense to embed them unless the collection is starting to be really big and would hurt the entity loading performance or reach the MongoDB document size limit
That surprises me, with such a name I would have expected to fully embed it all in the main document (including properties). The concern on sizes is where the user should make a choice in how it's mapped (using embedded or not).
That surprises me, with such a name I would have expected to fully embed it all in the main document (including properties). The concern on sizes is where the user should make a choice in how it's mapped (using embedded or not).