- Issue created by @seanB
- Status changed to Needs review
8 months ago 7:24am 8 May 2024 - π³π±Netherlands seanB Netherlands
Attached is a patch that adds static caching. This reduced the number of queries in a layout builder edit page from 912 to 227.
Before:
After:
- π³π±Netherlands seanB Netherlands
We can't simply update the static cache when it is updated, so lets unset it. Sorry about that.
- Status changed to Needs work
8 months ago 1:35pm 8 May 2024 - πΊπΈUnited States smustgrave
Can we turn to an MR first? (let reporter do it).
Also should we add test coverage now or should this be framework first
- Merge request !8015Issue #3445909: Add static caching to LayoutTempstoreRepository β (Closed) created by seanB
- Status changed to Needs review
8 months ago 2:20am 10 May 2024 - π³π±Netherlands seanB Netherlands
Added a MR. Not sure what the best approach would be to add test coverage. This shouldn't really change anything, except maybe the number of queries to the database. Also would love to get feedback from the framework managers if this is something they would consider adding.
- π³π±Netherlands seanB Netherlands
This caused quite some issues. It probably makes more sense to add the caching to LayoutTempstoreRepository. This solves the issue I experienced with a lot less impact. Updated the MR and IS.
- π³π±Netherlands seanB Netherlands
Tests are all green with the latest changes in the MR. Impact on the amount of queries is the same. From about a 1000 queries to 250 queries for a page with a bunch of layout builder components. π
- πΊπΈUnited States smustgrave
Do wonder if this will need test coverage? To my knowledge we don't have performance tests on layout builder, which would be very out of scope here.
- Status changed to RTBC
7 months ago 12:29pm 14 May 2024 - πΊπΈUnited States smustgrave
Going to mark but maybe a follow up for layout builder performance should be opened? That's a question for the committer. But the change here looks good.
- Status changed to Needs work
7 months ago 9:41am 15 May 2024 - π¬π§United Kingdom alexpott πͺπΊπ
I think the implementation here is fine and I think testing this beyond that is has not broken anything is fine. And the manual testing provided by @seanB is good. Just a small nit on the MR to address. Also the fact that so many queries are necessary on the page is a bug.
- Status changed to Needs review
7 months ago 8:38pm 15 May 2024 - Status changed to RTBC
7 months ago 11:58pm 15 May 2024 - Status changed to Needs review
7 months ago 12:23pm 21 May 2024 - Status changed to RTBC
7 months ago 1:36pm 30 May 2024 - πΊπΈUnited States smustgrave
Moving back to RTBC because thread has an answer.
- π¬π§United Kingdom longwave UK
Was debating whether we should use a static cache service here and inject it, or not to bother; given we can always swap to using a service later if we need to let's just get this in as a nice performance improvement.
Backported to 10.3.x as an eligible bug fix.
Committed and pushed 27c9bcca6f to 11.x and 076279a6c4 to 11.0.x and 282aed1317 to 10.4.x and d9111a4782 to 10.3.x. Thanks!
-
longwave β
committed d9111a47 on 10.3.x
Issue #3445909 by seanB, smustgrave, alexpott, catch: Add static caching...
-
longwave β
committed d9111a47 on 10.3.x
-
longwave β
committed 282aed13 on 10.4.x
Issue #3445909 by seanB, smustgrave, alexpott, catch: Add static caching...
-
longwave β
committed 282aed13 on 10.4.x
-
longwave β
committed 076279a6 on 11.0.x
Issue #3445909 by seanB, smustgrave, alexpott, catch: Add static caching...
-
longwave β
committed 076279a6 on 11.0.x
-
longwave β
committed 27c9bcca on 11.x
Issue #3445909 by seanB, smustgrave, alexpott, catch: Add static caching...
-
longwave β
committed 27c9bcca on 11.x
- Status changed to Fixed
7 months ago 10:34pm 7 June 2024 Automatically closed - issue fixed for 2 weeks with no activity.