DDC-3257: [GH-1112] DefaultRepositoryFactory: single repository for aliased entities #4029

Closed
opened 2026-01-22 14:34:01 +01:00 by admin · 3 comments
Owner

Originally created by @doctrinebot on GitHub (Aug 18, 2014).

Originally assigned to: @Ocramius on GitHub.

Jira issue originally created by user @doctrinebot:

This issue is created automatically through a Github pull request on behalf of giosh94mhz:

Url: https://github.com/doctrine/doctrine2/pull/1112

Message:

The actual implementation of DefaultRepositoryFactory create multiple instances for a single entity if is accessed by multiple namespace aliases.

I've patched DefaultRepositoryFactory::getRepository so that aliases are resolved before saving the reference into the repositoryList.

Just to not affect performance of existing implementation, I've added to the repositoryList both the aliased class name and the fully-qualified class name, but only the latter is required.

Originally created by @doctrinebot on GitHub (Aug 18, 2014). Originally assigned to: @Ocramius on GitHub. Jira issue originally created by user @doctrinebot: This issue is created automatically through a Github pull request on behalf of giosh94mhz: Url: https://github.com/doctrine/doctrine2/pull/1112 Message: The actual implementation of `DefaultRepositoryFactory` create multiple instances for a single entity if is accessed by multiple namespace aliases. I've patched `DefaultRepositoryFactory::getRepository` so that aliases are resolved before saving the reference into the `repositoryList`. Just to not affect performance of existing implementation, I've added to the `repositoryList` both the aliased class name and the fully-qualified class name, but only the latter is required.
admin added the Improvement label 2026-01-22 14:34:01 +01:00
admin closed this issue 2026-01-22 14:34:01 +01:00
Author
Owner

@doctrinebot commented on GitHub (Aug 18, 2014):

Comment created by @doctrinebot:

A related Github Pull-Request [GH-1112] was assigned:
https://github.com/doctrine/doctrine2/pull/1112

@doctrinebot commented on GitHub (Aug 18, 2014): Comment created by @doctrinebot: A related Github Pull-Request [GH-1112] was assigned: https://github.com/doctrine/doctrine2/pull/1112
Author
Owner

@doctrinebot commented on GitHub (Aug 18, 2014):

Comment created by @doctrinebot:

A related Github Pull-Request [GH-1112] was closed:
https://github.com/doctrine/doctrine2/pull/1112

@doctrinebot commented on GitHub (Aug 18, 2014): Comment created by @doctrinebot: A related Github Pull-Request [GH-1112] was closed: https://github.com/doctrine/doctrine2/pull/1112
Author
Owner

@doctrinebot commented on GitHub (Aug 18, 2014):

Issue was closed with resolution "Fixed"

@doctrinebot commented on GitHub (Aug 18, 2014): Issue was closed with resolution "Fixed"
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: doctrine/archived-orm#4029