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

Improve layout cache efficiency by de-duplicating XML strings. #104

Merged

Conversation

colinmollenhour
Copy link
Member

As announced a while back and made public first here: https://gist.github.com/colinmollenhour/14ed23d029e5b991a3e31ad1fe0841d4

I've been using this in production for months now with no issues. Massive cache storage savings.

@seansan
Copy link
Contributor

seansan commented Sep 29, 2016

I dus not sive info the code ... But how would this influence FPC cache extensions like lesti, mirasvit aheadworks amasty and others alike?

@colinmollenhour
Copy link
Member Author

@seansan If you have the layout cache enabled then it will significantly reduce the amount of cache storage used (and data written). That is all, but in cases where cache storage is valuable (such as in-memory caches like Redis, Memcache, etc.) it is quite important.

@Flyingmana
Copy link
Contributor

From the code I think there can happen collisions if the same update with different handles is used

@colinmollenhour
Copy link
Member Author

It is the full XML that is hashed, not just a list so the only possibility for collision is in the sha1 space which I think is pretty reasonable.

@Flyingmana Flyingmana added the review needed Problem should be verified label Oct 6, 2016
@colinmollenhour colinmollenhour merged commit 42abe71 into OpenMage:1.9.2.4 Oct 25, 2016
@colinmollenhour
Copy link
Member Author

Merged 1.9.2.4 into 1.9.3.0

@colinmollenhour colinmollenhour deleted the improve-layout-cache branch October 25, 2016 23:28
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Dec 6, 2017
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Feb 28, 2018
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Mar 20, 2018
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Jul 17, 2018
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Sep 19, 2018
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Feb 14, 2019
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Apr 1, 2019
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Aug 22, 2019
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Oct 25, 2019
@sreichel sreichel added Component: Core Relates to Mage_Core performance Performance related labels Jun 6, 2020
edannenberg pushed a commit to edannenberg/magento-lts that referenced this pull request Aug 20, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Component: Core Relates to Mage_Core performance Performance related review needed Problem should be verified
Projects
None yet
Development

Successfully merging this pull request may close these issues.

6 participants