title: Configure apache server to handle only one request at time
body: <p>As <code>apache</code> creates a new thread on new client request. so I wanted to configure apache to create an only single thread so it will not be able to handle more than one request at a time.</p>
  
  <p><strong>What I have done</strong></p>
  
  <p>Changes in apache <code>httpd-mpm.conf</code> <code>mpm_winnt_module</code> module</p>
  
  <pre><code>&lt;IfModule mpm_winnt_module&gt;
      ThreadsPerChild        1
      MaxConnectionsPerChild   0
  &lt;/IfModule&gt;
  </code></pre>
  
  <p>Created a <code>block.php</code> which keep script sleep for 30 sec</p>
  
  <pre><code>&lt;?php
      sleep(30);
      phpinfo();
      echo "Done";
  ?&gt;
  </code></pre>
  
  <p>Created a <code>hello.php</code> which print hello</p>
  
  <pre><code>&lt;?php
   echo "hello";
  ?&gt;
  </code></pre>
  
  <p>Now what should be happening is when running <code>block.php</code> apache will create a new thread for it will take 30 sec to execute. In this 30sec the threads will busy.
  At the same time, if I run <code>hello.php</code> it should not run because I have configured apache to create only one thread so <code>hello.php</code> should not be executed at the same time it should wait for 30sec.</p>
  
  <p>But this is not working as I am thinking, is there anything I am missing? I just wanted to understand apache multithreading behavior.</p>