Why is annotating mappable classes necessary? #2981
bendherville
started this conversation in
General
Replies: 1 comment 4 replies
-
With lazy evaluation of the mapping, having no mapping information isn't necessarily a problem. (Though it has resulted in the odd bug over the years.) But morphia is taking a more forward looking, proactive view as time passes where knowing the mapped entities makes mapping both easier to implement and more performant for users. In 3.x, this mapping is likely to happen more at build time than runtime so knowing which types are of interest is paramount at that point. |
Beta Was this translation helpful? Give feedback.
4 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We are migrating from morphia 1.x to 2.4 and having to add annotations to all of our classes that are used as top-level or embedded types (there are lots of them). Not complaining about doing work :) but the question is why is this necessary in v2.4? Can't it be assumed that a type being persisted is mappable and use the same defaults as applied to classes annotated with
@Entity
?Beta Was this translation helpful? Give feedback.
All reactions