-
Notifications
You must be signed in to change notification settings - Fork 20
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
WIP: Testing/public folder #931
base: main
Are you sure you want to change the base?
Conversation
Ran an initial comparison using ApacheBench on my Intel MacBook: Specs:Intel OSX 11.5.2, 32GB Apache Bench Test - 100 requests, 1 concurrent
Outcome - No performance increaseTest 1: Original Configuration (main)
Test 2 - public folder (testing/public-folder)
|
AFAIKT, after testing no real performance increase 😢. I also think this change is a bit too heavy handed with the restructure and would make it even more work to adapt to other hosting filesystem configurations. I'd like to discuss a bit more how we could decouple |
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.
Hold for discussion
@nickpelton thank you so much for this! Would it be too much to ask to rerun the public folder test after a system prune? I know it's a pain because you'd have to download the docker images again, but it would ensure there aren't any left over volumes hanging around that could be still mounted/skewing the results? If it comes back the same then this change is definitely not worth it. so global:stop-all; docker system prune --all --force --volumes so start |
Most of |
@nickpelton oh also, maybe some |
Test 2Ran so global:stop-all; docker system prune --all --force --volumes then reran tests. Specs: Apache Bench Test - 100 requests, 1 concurrentab -n 100 -c 1 https://square1.tribe/ Outcome - Ran (way) faster due to the prune command, but no real performance change.Test 1: Original Configuration (main)
Test 2: Public (testing/public-folder)
|
Now that's very interesting about the prune making things significantly faster all around. However, the mean is 9.6% faster and the max is 23% faster. That's not insignificant. I don't think anyone on a mac is getting sub 500ms loading times period though. If you have time tomorrow, would love to do some pair coding so I can check a few things. |
What does this do/fix?
Moves only what needs to be in the PHP-FPM container into a
public
folder, reducing the amount of files inside the container and in theory, having some performance improvement for macOS users. Things likenode_modules
which has so many files that do not need to be in the container and contribute to large copies and slow downs.This PR is more to just start the discussion and have some of those with slower machines give it a test and see if they notice any differences and to see if this change would be worth it long term.
So any of you with
so
and a Mac, would love a before/after comparison, if possible, please!Enough of these small improvements will add up to a faster local, and a single mounted folder will make a more complete performance solution easier to implement.
Benchmark instructions
Before switching to this branch, get a feel for loading times after caches have been primed. The page load time chrome extension is great for this.
so xdebug off
so composer install
Testing instructions
so stop
.env
file into public (so
would need to be updated to account for this)so start
so xdebug off