your issues are under investigation, we'll report immediately as soon as we solve them.
Announcement
Collapse
No announcement yet.
X
-
An update - the problem here is that the setProperties() call needs to create related entities, and assumes it's going to have an EntityManager available to do this.
But an EntityManager is normally only created as part of actual execution of a DSRequest - in that situation we have a clear context for what's going to happen to the bean, whether a transaction is involved, etc.
When we are just asked to populate a bean in the midst of a DMI there's no context that would allow us to correctly create an EntityManager.
What we are looking at doing is just avoiding the crash and creating your related entities as detached beans. You would then need to create an EntityManager to perform JPA save operations with the nested bean structure. Does that make sense for your use case?
Comment
-
Your issues are fixed and can be found in next (2014.03.14) nightly build. Please see details below
- fixed support for saves that involve Embeddable
- resolved the ClassCastException that could result if you use a mixture of JPA and non-JPA DataSources to describe a nested bean structure and try to populate the nested structure with DataSource.setProperties().
- resolved the NPE that could occur if you used DataSource.setProperties() to populate a nested bean structure outside of the context of a JPA operation (due to lack of an EntityManager). As mentioned earlier in this case we will create related entities as detached beans.
Comment
Comment