Namespace awareness #33

Open
opened 2026-09-02 20:01:02 +02:00 by c.fahner · 0 comments
Owner

Currently it is not possible to separate entities into namespaces. Frameworks could use such a feature to separate collections belonging to different modules using a different prefix.

An interface Database\NamespaceAware should be added which allows specifying a mapping function from Entity class to full collection name. Without such a mapping, enforceSchema() cannot resolve foreign keys.

The slendium/ocd-conformance-tests package should include tests to ensure namespace awareness is properly implemented.

Currently it is not possible to separate entities into namespaces. Frameworks could use such a feature to separate collections belonging to different modules using a different prefix. An interface `Database\NamespaceAware` should be added which allows specifying a mapping function from `Entity` class to full collection name. Without such a mapping, `enforceSchema()` cannot resolve foreign keys. The slendium/ocd-conformance-tests package should include tests to ensure namespace awareness is properly implemented.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set

Reference
slendium/ocd#33
No description provided.