Skip to content
This repository has been archived by the owner on Sep 16, 2021. It is now read-only.

[WIP] Block: cache - add config to enable esi #181

Merged
merged 2 commits into from
Jul 10, 2013

Conversation

rmsint
Copy link
Contributor

@rmsint rmsint commented Jul 9, 2013

Documentation added for symfony-cmf/block-bundle#84 to enable esi in Symfony configuration.

Changes will be updated after #179 is merged.

@wouterj
Copy link
Member

wouterj commented Jul 9, 2013

Could you please also add xml and php config?

@@ -71,18 +71,18 @@ CmfBlockBundle and the SonataBlockBundle:
3. *SonataBlockBundle* - Use the ``sonata_block`` key to configure the cache
adapter for each block service:

.. configuration-block::
.. configuration-block::
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@wouterj this config is currently broken: http://symfony.com/doc/master/cmf/bundles/block/cache.html#installation

I am not sure if this will fix it. Do you know what the notation should be for putting a config block in a list?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ones you changed are wrong, from the ReSt reference:

List item bodies must be left-aligned and indented relative to the bullet; the text immediately after the bullet determines the indentation.

The problems are the XML and PHP formats, those are indented with 8 spaces intead of the expected 7 spaces. If you change them here and in the block on line 45, it'll work.

@rmsint
Copy link
Contributor Author

rmsint commented Jul 10, 2013

I tried to add the xml config, however I cannot figure out some parts. Maybe you have a tip for me where I can learn about it? I checked the http://symfony.com/doc/current/reference/index.html, however it only contains some snippets.

@wouterj
Copy link
Member

wouterj commented Jul 10, 2013

Sorry, you must have misunderstood me. I meaned only the XML and PHP for the changes you made, the others are added in #179

@rmsint
Copy link
Contributor Author

rmsint commented Jul 10, 2013

ok, then I will wait untill #179 is merged and add the changes then.

lsmith77 added a commit that referenced this pull request Jul 10, 2013
[WIP] Block: cache - add config to enable esi
@lsmith77 lsmith77 merged commit 472a0bd into symfony-cmf:master Jul 10, 2013
@wouterj
Copy link
Member

wouterj commented Jul 10, 2013

This should not have been merged, I now get a lot of conflicts...

@lsmith77
Copy link
Member

oops .. sorry .. didnt read the text closely enough :(
what should we do now? remove the commits? revert the change?

@wouterj
Copy link
Member

wouterj commented Jul 10, 2013

Never remove commits in a public repo :)

We could revert 9795d68 and I'll update #179 to include the important changes from that commit. Then, we can say this PR is merged (because 53de460 contains the important stuff).

@lsmith77
Copy link
Member

can you open PRs for this? I am struggling to at least get new tags out today for jackalope

@wouterj
Copy link
Member

wouterj commented Jul 10, 2013

I'll do later this afternoon (I can also push the revert commit immediately without a PR if that helps you)

@rmsint
Copy link
Contributor Author

rmsint commented Jul 10, 2013

oops, if the code is reverted, the change that we should have as result is:

# app/config/config.yml
framework:
    # ...
    esi:             { enabled: true }
    fragments:       { path: /_fragment } # enable FragmentListener to automatically validate and secure fragments
    trusted_proxies: [192.0.0.1, 10.0.0.0/8] # add varnish server ip-address(es)

I forgot to mention the fragments and trusted_proxies in 53de460 and added them in the other commit.

@wouterj wouterj mentioned this pull request Jul 10, 2013
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants