Open alcaeus opened 4 years ago
Excellent information @alcaeus, thank you very much. This will help moving the next versions forward for compatibility.
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions.
Is any update on this bug. Facing same issue. I am not able to use gedmo:timestampable
with monogb.xml
FWIW cross referencing https://github.com/doctrine/mongodb-odm/pull/2607 where we try to allow namespaced elements in ODM's schema
MongoDB ODM 2.0 introduces schema validation for ODM mapping files. This means that any mapping file containing gedmo extensions will be considered invalid by ODM. ORM used to have an
xs:any
element in all types to allow for extra elements, but this will no longer be possible in ORM: 3.0: https://github.com/doctrine/orm/commit/af0b0dbdc397b8c8fcc6cf4eb2e5ea0920dbd6bd.With that said, ODM 2.0 (and most likely ORM 3.0) will require a new way to provide mappings for the extensions when using XML. One option is to no longer load gedmo mappings from the Doctrine mapping files, but instead use separate files for any additional behaviour.
Another option would be to extend the Doctrine schema to extend all types that support gedmo elements. This would require a configurable XSD path for the XML mapping drivers. However, this would require some thinking as to how to guarantee that the mappings are still valid from a Doctrine standpoint (e.g. without the extra gedmo mappings).
As it is, users of MongoDB ODM 2.0 and possibly ORM 3.0 will not be able to use Gedmo extensions.
Edit: cross-referencing original bug report in ODM: https://github.com/doctrine/mongodb-odm/issues/2095