-
-
Notifications
You must be signed in to change notification settings - Fork 4.5k
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
Optimization opportunities for composer metadata loading #7443
Comments
To give more context about this. We were discussing about reducing installation time for a PHP app that has these simple "require": {
"php": "^7.1.3",
"ext-ctype": "*",
"ext-iconv": "*",
"symfony/console": "^4.0",
"symfony/flex": "^1.0",
"symfony/framework-bundle": "^4.0",
"symfony/lts": "^4@dev",
"symfony/yaml": "^4.0"
},
"require-dev": {
"symfony/dotenv": "^4.0"
}, I mentioned that it's sad that JavaScript's In any case, I profiled a simple |
Please, try to keep comparisons / mentions of other package managers of other languages out of the discussion. |
Thanks for the advice ... but I recommend to do the opposite. Please, look at many other package managers as possible to get great ideas from them. There will be obvious unavoidable differences because each programming language has its own features and some of them can't be translated to PHP. But other than that, please look for the great ideas implemented by other projects. Thanks! |
I meant mentions like these:
This contributes nothing useful to the discussion. |
I think it was useful because it can lead to massive improvements. For example, when running |
See, that is actually useful. Talking about features / implementation details. Parallel requests are already possible through some extensions/plugins. I am pretty sure they are also already on the roadmap for Composer 2.x as well. I was just saying that comments like "X is fast and Composer is slow" do not help. |
Parallel downloads are needed so badly. Our project that uses a lot of Wordpress plugins could take 5 minutes for composer update to complete, all because it downloads many repos from wpackagist one by one. Is there a better ticket to watch for parallel downloads implementation? |
Not really. You can already use https://github.com/hirak/prestissimo in the meanwhile. |
I love you! |
Please keep this issue focused. Parallel downloads are totally unrelated to the optimization suggested here (there are other issues discussing them) |
Composer 2 is coming 🥳 |
@javiereguiluz made some analysis of a run of composer in symfony/skeleton#66 (comment) (he can probably share the corresponding blackfire profile).
Regarding the
strtolower
calls, an idea might be to make a special case for Packagist repositories (with an opt-in for any other custom repo of course, but it would be enabled for the builtin repo), which could rely on the fact that package names are already lowercased in the downloaded metadata (I'm quite sure that's already the case, and it would not be hard to implement otherwise).This way, composer would not need to process the package names to make them lowercase.
The text was updated successfully, but these errors were encountered: