Details
Description
In contrast to its JavaDoc documentation, the method XWikiDocument.readObjectsFromFormUpdateOrCreate() does support ids that are non-continuous and doesn't ignore them (however, the URL documentation describes that they are supported). Instead, it adds these objects twice - once at the next free id and then again at the specified id. These are two references to the exactly same Java object so I think they might be de-duplicated again during serialization/unserialization and the object definitely won't be saved twice in the database so the impact on existing data should be limited.