Issue Details (XML | Word | Printable)

Type: New Feature New Feature
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Bertrand NOEL
Votes: 0
Watchers: 0

If you were logged in you would be able to see more operations.
DataNucleus Store MongoDB

Support inherited embedded Map keys/values

Created: 20/Dec/12 02:09 PM   Updated: 20/Dec/12 07:21 PM
Component/s: Persistence
Affects Version/s: 3.2.0.m1
Fix Version/s: None

File Attachments: 1. Zip Archive (3 kB)

Linux (Ubuntu)
MongoDB last version

Forum Thread URL:
Datastore: MongoDB

 Description  « Hide
I am using Datanucleus/JDO to persist objects in a MongoDB DB. I try to persist an object containing a Map, which value type is an abstract class.
When I try to persist an instance of that object, fields of the abstract class are persisted, but not those of the child class.
Below is some code as an example.

Bertrand NOEL made changes - 20/Dec/12 02:11 PM
Field Original Value New Value
Attachment [ 11830 ]
Bertrand NOEL added a comment - 20/Dec/12 02:12 PM - edited
Code is not "below", it is in the attached file. Sorry I submitted too quickly and I cannot edit my text.

Andy Jefferson added a comment - 20/Dec/12 07:21 PM
Nowhere in the docs does it say that inherited embedded map keys/values are supported. In fact JDO3 and JPA2 don't define any support for them. JDO3.1 introduces some support, but currently only supported for collection elements with inheritance.

Andy Jefferson made changes - 20/Dec/12 07:21 PM
Summary Child of astract in map value not persisted Support inherited embedded Map keys/values
Issue Type Bug [ 1 ] New Feature [ 2 ]