title: CXF increase connection pool size without changing http.maxConnections
body: <p>I have recently been asked to configure CXF to the same parameters as our older XFire service. </p>
  
  <p>One of those parameters was <code>Keep-Alive: timeout=60, max=20</code>. 
  However, I did some research and it appears that CXF uses the JVM <code>HttpURLConnection</code> object under the hood. <a href="https://issues.apache.org/jira/browse/CXF-291" rel="nofollow">From what I see</a>, there has been some attempts to provide configuration for it but nothing has been commited for now.</p>
  
  <p>I would prefer not to change the <code>http.maxConnections</code> parameter as it would impact all the server instead of the CXF web services only.</p>
  
  <p>I found this <a href="http://cxf.547215.n5.nabble.com/HTTP-Connection-Pooling-td561783.html" rel="nofollow">interresting forum thread</a> talking about it where Daniel Kulp says:</p>
  
  <blockquote>
    <p>BTW: there is a way to control the connection pooling, but it's a
    SERVER side  thing.   Basically, if the server sends back a header of:</p>
    
    <p><code>Keep-Alive: timeout=60, max=5</code> </p>
    
    <p>then the Java client will respect those values.    Right now in CXF,
    you would  probably need to write an interceptor to set those values. 
    I just made a  commit to trunk that expands the http configuration to
    include a setting to  control this from the config file.</p>
  </blockquote>
  
  <p>I could write an interceptor that modify the headers to do so. However my question is: How will the server react to this kind of change? Would not that be a problem if the server expects 5 connections max and the client performs more ?</p>