Closed (fixed)
Project:
Memory limit policy
Version:
8.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
21 Jul 2020 at 09:47 UTC
Updated:
29 Apr 2022 at 15:09 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
sharique commentedI checked the memory limit policy module, and it works on "KernelEvents::REQUEST", which doesn’t work in case of Drush. We need to look for any other approach to increase the memory limit for Drush commands.
https://git.drupalcode.org/project/memory_limit_policy/-/blob/8.x-1.x/sr...
Kernel request event only works the case of HTTP request (browser/curl). Drush commands very differently, currently there isn't any event that fired at the start of Drush command, introducing an event at beginning of Drush command can an option.
Comment #3
rahul.shindeComment #4
rahul.shindeAdding a new module supporting drush contraints.
Resources that I refered,
Comment #5
sharique commentedThanks a lot Rahul for posting a patch. Following are my review comments and suggestions.
It only take mymodule:doSomething but not do-something.
I'm using Drush version 10.3.1,
Comment #6
rahul.shindeComment #7
rahul.shindeUploaded the new patch adding README file.
@Sharique Please review.
Comment #8
sharique commentedAliases also working fine now. Thanks Rahul for patch.
Comment #10
vbouchetThanks for the patch and the review.
I adapted the code following https://www.drupal.org/project/memory_limit_policy/issues/3185785 but it is a really minor change.
I merged the code in 8.x-1.x branch.
Thanks again for the new feature.