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

Default query cache using wrong object #5854

Closed
lcobucci opened this issue Jun 5, 2016 · 2 comments
Closed

Default query cache using wrong object #5854

lcobucci opened this issue Jun 5, 2016 · 2 comments
Assignees
Milestone

Comments

@lcobucci
Copy link
Member

lcobucci commented Jun 5, 2016

On the fix of PHP 7 bug, ReflectionProperty#getValue() is now raising a Notice when accessing an undefined property. That change revealed a false positive on ORM tests!

As you can see here the DefaultQueryCache is always trying to fetch data from $entity even when the association is not with that object (the test is failing because DefaultQueryCache is trying to get the country from the City instead of the State).

How to reproduce: execute the test suite while running PHP 7.0.7

@Ocramius
Copy link
Member

Ocramius commented Jun 5, 2016

@lcobucci can you take a look at #5856? It fixes the issue, but also disables some of the SLC caching happening during hydration of multi-level DQL fetch-joins.

Ocramius added a commit that referenced this issue Jun 5, 2016
…iated against the wrong class name in a test
Ocramius added a commit that referenced this issue Jun 5, 2016
FabioBatSilva pushed a commit that referenced this issue Jun 17, 2016
FabioBatSilva pushed a commit that referenced this issue Jun 17, 2016
…iated against the wrong class name in a test
Ocramius added a commit that referenced this issue Jun 19, 2016
…test-using-wrong-reflection-instance

#5854 workaround to avoid populating Second Level Cache from DQL queries with multiple nested DQL aliases
@lcobucci
Copy link
Member Author

lcobucci commented Jan 7, 2017

@Ocramius I totally forgot to do a follow up on this issue here.

I'd say it's fixed, let's close it?

@Ocramius Ocramius closed this as completed Jan 7, 2017
@Ocramius Ocramius self-assigned this Jan 7, 2017
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

2 participants