|
I have an entity (User) which contains an embedded document (EmbeddedList) which contains an @ElementCollection List<String> and another field. As soon as I try to save the user with an empty embedded document, the process fails with "com.mongodb.MongoException$DuplicateKey error" although the entity has not been stored so far. The weird stuff happens if I remove all fields in the embedded document except the list. It suddenly works totally fine. I also added a second test case (testSingleResultQueryWithEmbeddedList) where the querying of a user throws a nullpointer.
Pull request: https://github.com/hibernate/hibernate-ogm/pull/355
|