title: Memory limit of a Symfony 2 application
body: <p>My Symfony application is using a lot of memory for a reason I do not quite understand (I am not processing images or anything that I think would be heavy on memory).</p>
  
  <hr>
  
  <p>I can see from <a href="https://stackoverflow.com/questions/3882817/is-a-128mb-php-memory-limit-a-lot">here</a> that 128M of memory limit is very high...and that no one should ever need that much memory.</p>
  
  <p>php.ini file:</p>
  
  <pre><code> memory_limit = 128M; 
  </code></pre>
  
  <hr>
  
  <p>I believe people have to deal with this too within a Symfony application, so I was wondering if I could have some input on the following:</p>
  
  <ol>
  <li>Is 128M manageable, or is this really amazingly high? What do people use in general within a Symfony app, and what is the maximum I should tend to go to?</li>
  <li>What can I do to improve this, is there a way to debug memory issues?</li>
  <li>Are there any processes that use a lot of memory that I should be aware of while coding? </li>
  </ol>
  
  <p>(I for example noticed that injecting many services in a class via the DIC could require more memory, even if I can't guarantee this, I am just raising the question whether or not there are some important things a coder should know to avoid using too much memory, like using the DIC with care for example..).</p>