Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
Re: [eclipselink-dev] Opinion request: Persisting non-entity subclass of Entity

I have just added comments to bug 237281 about the entity hierarchy that reproduces the error.

Tom Ware wrote:
Hi Folks,

  I am wondering if anyone has an opinion about the following:

At the moment, EclipseLink does not throw an exception when you persist a subclass of an Entity that is not annotated as an Entity. Instead, it treats it as though it is the superclass and persists the superclass.

  The following bug has been entered because of this issue:

https://bugs.eclipse.org/bugs/show_bug.cgi?id=237281

Note: Although the bug claims we throw the incorrect exception in this case, my recreation of this issue shows we continue without any issue at all.

It seems that although the EclipseLink behavior actually allows some additional use cases not supported by the spec, this behavior is, strictly speaking, a spec violation.

Does anyone have an opinion about whether we should keep the current behavior as an option?
I am not able to think of a use case when a user want to use such pattern. Can you please give an example.

Thanks,
Mitesh


Thanks in advance,
Tom
_______________________________________________
eclipselink-dev mailing list
eclipselink-dev@xxxxxxxxxxx
https://dev.eclipse.org/mailman/listinfo/eclipselink-dev


Back to the top