title: Performance degradation after moving to jersey 2
body: <p>We're working on a server using spring 4, embedded jetty 9 and jersey. Recently, we moved to jersey 2.13 and we noticed a degradation in performance. I performed some investigations using YourKit. I saw that there is a massive CPU usage in reflection done by jersey. Also, there are many <code>NoSuchMethodExceptions</code> and <code>ClassNotFoundExceptions</code> in Yourkit snapshot.</p>
  
  <p><img src="https://i.stack.imgur.com/SOwgi.png" alt="enter image description here"></p>
  
  <p>Are there any jersey configuration or a best practice to avoid this issue, or to optimize jersey? Or maybe it is a known issue in jersey 2?</p>
  
  <p>Here are two screenshots from YourKit, showing the hot-spots, after excluding the socket read (<code>java.net.SocketInputStream.socketRead0</code>). The first one is with Merged Callees:</p>
  
  <p><img src="https://i.stack.imgur.com/4tR3p.png" alt="enter image description here"></p>
  
  <p>And the second one is with Back Trace:</p>
  
  <p><img src="https://i.stack.imgur.com/HssNH.png" alt="enter image description here"></p>
  
  <p>Thanks.</p>