title: How can i add the options of a REST call to a header as a parameter?
body: <p>I am using an ESB to route data between SQL and REST calls. So far this is working fine, however when i want to add options to the REST call. For example:</p>
  
  <pre><code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
  &lt;blueprint xmlns="http://www.osgi.org/xmlns/blueprint/v1.0.0"&gt;
  
      &lt;camelContext xmlns="http://camel.apache.org/schema/blueprint"&gt;
          &lt;propertyPlaceholder id="placeholder"
               location="file:${karaf.home}/etc/nl.test.astron.sql.cfg" /&gt;
  
  
  &lt;restConfiguration bindingMode="json" component="servlet"&gt;
              &lt;endpointProperty key="servletName" value="ASTRONServlet" /&gt;
          &lt;/restConfiguration&gt;
  
          &lt;rest path="/get/astrondata"&gt;
              &lt;get uri=""&gt;            
                  &lt;to pattern="InOut" uri="direct:get" /&gt;         
              &lt;/get&gt;
          &lt;/rest&gt;
  
          &lt;route id="get_to_uri"&gt;
              &lt;from uri="direct:get"/&gt;
              &lt;setHeader headerName="boundRaMin"&gt;
                  &lt;simple&gt;70&lt;/simple&gt;
              &lt;/setHeader&gt;
              &lt;setHeader headerName="boundRaMax"&gt;
                  &lt;simple&gt;90&lt;/simple&gt;
              &lt;/setHeader&gt;
              &lt;setHeader headerName="boundDecMin"&gt;
                  &lt;simple&gt;0&lt;/simple&gt;
              &lt;/setHeader&gt;
              &lt;setHeader headerName="boundDecMax"&gt;
                  &lt;simple&gt;30&lt;/simple&gt;
              &lt;/setHeader&gt;    
              &lt;to uri="sql:{{sql.getDatabase}}?
                  outputType=SelectList&amp;amp;
                  greedy=true&amp;amp;
                  useIterator=false"/&gt;
          &lt;/route&gt;
  </code></pre>
  
  <p>and the SQL code is:</p>
  
  <pre><code>sql.getDatabase=SElECT * FROM dbo.astron_data WHERE :#boundRaMin&lt;ra AND 
                  ra&lt;:#boundRaMax AND :#boundDecMin&lt;dec AND dec&lt;:#boundDecMax
  </code></pre>
  
  <p>As one can see here, boundRaMin,boundRaMax,boundDecMin,boundDecMax are all set by in the headers, However i want to make these variable depending on the options defined in the rest call. Thus for example the following call:</p>
  
  <p><a href="http://localhost:8080/astron/get/astrondata?boundRaMin=value1&amp;boundRaMax=value2&amp;boundDecMin=value3&amp;boundDecMax=value4" rel="nofollow noreferrer">http://localhost:8080/astron/get/astrondata?boundRaMin=value1&amp;boundRaMax=value2&amp;boundDecMin=value3&amp;boundDecMax=value4</a></p>
  
  <p>should fill the right values of value1...value4 into the headers. It seems that these query parameters do not get mapped to the headers.</p>