What is this guy doing that he needs gigabytes of memory to install a bunch of php libraries?
Before: Memory usage: 2194.78MB (peak: 3077.39MB), time: 1324.69s
After: Memory usage: 4542.54MB (peak: 4856.12MB), time: 232.66sWhat is this guy doing that he needs gigabytes of memory to install a bunch of php libraries?
Before: Memory usage: 2194.78MB (peak: 3077.39MB), time: 1324.69s
After: Memory usage: 4542.54MB (peak: 4856.12MB), time: 232.66sThat's the reason for the huge memory usage. We're slowly moving away from PEAR, but since it works for now not everyone has/will transition.
Edit: I should also point out that there are a few packages that almost everyone uses (PHPMD, PHPCS, phpUnit) that are still mostly pulled from PEAR, though I think phpUnit has a composer option.
The reality is even in the above edge case: 2x memory, 6x speed.
Unless you're running your deployment on a 512Mb or 1G VM. I've had composer max out swap on those too. Even with 2G RAM it's not been happy sometimes, so be interesting to see what difference this patch makes.
To add/update any dependencies for your project run the composer.phar update on your development environment or somewhere it can use a ton of memory and cpu without issue. Then just commit and push up your composer.lock changes. Been doing it this way for over a year and had no issues deploying changes in ec2.
Question - why not run Composer locally, as part of deployment?