-
Notifications
You must be signed in to change notification settings - Fork 51
ServiceCircularReferenceException with BlockVarnishCache #192
Comments
It seems that the problem comes from the profiler, sonata block bundle adds |
thanks and good luck! please tell if you find something. its pretty busy here, did not have time to look into it myself. |
Hello gonzalovilaseca, |
I haven't had the time to look further, I found that if you disable the data_collector in the sonata bundle, you can temporarily fix it. I have to look further..I just don't know when I'll have the time. |
I'm not not sure that it is exactly the same error but I also have a circular reference. as the path is almost the same I was hopping that you solved it :-) |
@gonzalovilaseca I manage to isolate from where the problem was originate. The BlockBundle add into the profiler a custom dataCollector to show the blocks list in the profiler. I'm looking deeper to see if I have in my app a service that would require a service required by the vendor service. 'sonata.block.data_collector' declared in: vendor/sonata-project/block-bundle/DependencyInjection/SonataBlockExtension.php |
maybe the service that dataCollector service could be made lazy to solve the circularity issue? |
Thanks @dbu, I tried to set into the vendor definition to lazy but it didn't solve the circular reference. |
does the problem also occur with only sonata cache and sonata block, without cmf block? or does sonata do some clever trick with their service that we could mimick? |
Actually I have no idea, I just get a full web app with a lot of bundles configured. |
sorry, i also don't know enough why this starts to happen or what to do without digging deep into it - for which i unfortunately have no time at this point. can you deactivate profiling in the sonata block bundle to break the circle? |
@rmsint i think you originally added this. can you help us where this comes from? do you have any idea how to break the circle or where to look for the cause of that circle? |
Thanks for your reply, |
that could make sense yes. but would need to be done in the sonata bundle, not here, right? you would have to ask rande for sonata, or just propose a PR. |
Oo That's right, I thought I was on it. |
ping |
I haven't looked further, but this configuration disables de profiler listener:
|
I'm trying to run Esi with CMF Block bundle, but I'm getting this exception:
cmf.block.cache.varnish
needsfragment.handler
.The following call is done in a compiler pass on
fragment.handler
:And
fragment.renderer.inline
needshttp_kernel
, so a circular exception is raised.Any ideas on how to solve it?
The text was updated successfully, but these errors were encountered: