title: Why Reactive programming application( vert.x) is faster than single thread lock free , no-blocking java application?
body: <p>I recently tested a simple HTTP server using vert.x( java based) I was amazed by the throughput and api latency of http server, it is blazingly fast.</p>
  
  <p>The same piece of code of http-server was run on java application with single thread, lock free and non-blocking. Performance was less than 1/3rd of vert.x one.</p>
  
  <p>What I do not understand is, what is the core technical difference that the vert.x outperforms non-reactive java application ?</p>
  
  <p>STATS :</p>
  
  <p>Testing was done using Jmeter. Both jmeter and application was run on same machine- jmeter consuming cpu 25-50%, app consuming cpu 20-30% .
  All the tests were run for 5 minutes.</p>
  
  <ol>
  <li>Spring boot  with 1 tomcat worker thread :</li>
  </ol>
  
  <p>Jmeter with 1 client thread bombarding request (throughout :3474 per sec):
  <a href="https://i.stack.imgur.com/EI0E7.png" rel="noreferrer"><img src="https://i.stack.imgur.com/EI0E7.png" alt="enter image description here"></a></p>
  
  <p>Jmeter with 50 client thread bombarding request concurrently (throughout :4285 per sec):
  <a href="https://i.stack.imgur.com/L7vDk.png" rel="noreferrer"><img src="https://i.stack.imgur.com/L7vDk.png" alt="enter image description here"></a></p>
  
  <ol start="2">
  <li>Vert.x ( java based ) with only 1 vertical ( http processor vertical ) – meaning only 1 processor thread </li>
  </ol>
  
  <p>Jmeter with 1 client thread bombarding request (throughout :9382 per sec) :
   <a href="https://i.stack.imgur.com/EF9iH.png" rel="noreferrer"><img src="https://i.stack.imgur.com/EF9iH.png" alt="enter image description here"></a></p>
  
  <p>Jmeter with 50 client threads bombarding requests concurrently (throughout :20785 per sec):
   <a href="https://i.stack.imgur.com/G1JJR.png" rel="noreferrer"><img src="https://i.stack.imgur.com/G1JJR.png" alt="enter image description here"></a></p>