Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork5.2k
Updated installation instructions for lazy services#2778
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
Uh oh!
There was an error while loading.Please reload this page.
Conversation
the above command does). | ||
If you're using the full-stack framework, the proxy manager bridge is already | ||
included but the actual proxy manager needs to be included. Therefore add | ||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
missing.. code-block:: json
/cc@Ocramius |
@wouterj that's a bit debated. The problem is that installing |
Actually, can you include |
thank you for claryfing this@Ocramius . I knew you had some debate on the original PR about this one, but I didn't really follow that discussion that's why I pinged you. |
If you're using the full-stack framework, the proxy manager bridge is already | ||
included but the actual proxy manager needs to be included. Therefore add | ||
"ocramius/proxy-manager": ">=0.3.1,<0.4-dev" |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
what about:
..code-block::json"require": {"ocramius/proxy-manager":"0.4.*" }
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
0.3.1
is also in the working range. I don't see any problems with it though.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
sorry, I was not clear. I meaned the require block around it
Ok, just added as@wouterj mentioned. In general I had issues with the "missing" dependency, wouldn't it be a good solution if you get a warning if you set lazy: true to a service and you have not installed the proxy manager? Otherwise people intend to use the lazy services and they are silently not available. In addition to that Fabien was mentioning in his blog post about the draw backs of lazy services (http://symfony.com/blog/new-in-symfony-2-3-what-else), should we mention something about this as well? |
@Ocramius I have added the information about how to check if it works based on the interface. |
.. code-block:: php | ||
var_dump(class_implements($service)); | ||
If the class implements the ProxyManager\Proxy\LazyLoadingInterface your lazy |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others.Learn more.
the FQCN should be in a literal (double quotes)
@wouterj Updated as per your request. From my side it is good to be merged into 2.3.x and master. |
👍 thanks for contributing! |
qpleple commentedJul 12, 2013
+1 for this update in the doc |
Great job Peter and everyone else! I've patched this into the 2.3 branch - it's a very very good improvement! Cheers! |
If you use the full stack framework the proxy-manager-bridge is already included.
Therefore just the actual proxy-manager bundle needs to be installed and this
is adjusted with this PR.