Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DDC-3407: add possibility to prevent some entitiy methods from being proxied #4211

Closed
doctrinebot opened this issue Nov 21, 2014 · 6 comments
Assignees

Comments

@doctrinebot
Copy link

Jira issue originally created by user backbone:

This is for optimization of lazy loading, when using entity methods that operate only on identifier values.

This issue is partially addressed via:
ba38f3e

But it makes assumptions about a certain code style, that is for an "id" identifier property the getter is named "getId". but some code styles prefer "getID".

It would be nice to have an annotation like @Orm\SkipProxy (or equivalents for xml/yaml) to mark a method that should not be proxied.

@doctrinebot
Copy link
Author

Comment created by @Ocramius:

I wouldn't implement it that way. I'm actually building something (non-trivial) at Ocramius/ProxyManager#192 and Ocramius/ProxyManager#159, but it will take some time to get there, and also to get doctrine to use that component to generate proxy classes.

@backbone87
Copy link

@Ocramius Is their any update on this? From what i have seen the ProxyManager implemented the needed groundwork quite a while ago, are their any plans to make them available in the orm?

@DHager
Copy link
Contributor

DHager commented Feb 18, 2016

Hmm, is it better to do a broad/generic "non-initializing methods" feature, or would it be better to have a narrower way to specify "this method is a primary-key getter"?

@backbone87
Copy link

well if you use the proxymanager of ocramius the lazy loading is done on accessing props not methods

@Ocramius
Copy link
Member

#1241 is attempting to solve this issue as well

@Ocramius
Copy link
Member

Solved in #6719

@Ocramius Ocramius added this to the 3.0 milestone Aug 23, 2018
@Ocramius Ocramius assigned Ocramius and unassigned beberlei Aug 23, 2018
@greg0ire greg0ire removed this from the 3.0.0 milestone Jun 27, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

6 participants