How to perform POSt operation in Java via Request url and Request body?
<p>I want to perform POSt that will take 2 inputs, one is Request URL and other is Request Body and give output as Response body.</p>

<p>Input :</p>

<ol>
<li><p>Request URL. </p></li>
<li><p>Request Body.</p>

<p>Output :</p>

<p>Response Body :</p></li>
</ol>

<p>example :  </p>

<p>Request URL in the form :  http:///watson/search/bugs?appGUID=&amp;pagenumber=1&amp;pagesize=50</p>

<p>Format of Request body : </p>

<pre><code>&lt;criteria&gt;
&lt;includeFilterSets&gt;
    &lt;filterSet&gt;
        &lt;filter&gt;
            &lt;filterName&gt;PRODUCT_NAME&lt;/filterName&gt;
            &lt;operator&gt;
                &lt;name&gt;Equals&lt;/name&gt;
            &lt;/operator&gt;
            &lt;value&gt;Acrobat&lt;/value&gt;
        &lt;/filter&gt;
        &lt;filter&gt;
            &lt;filterName&gt;VERSION_NAME&lt;/filterName&gt;
            &lt;operator&gt;
                &lt;name&gt;In&lt;/name&gt;
            &lt;/operator&gt;
            &lt;value&gt;10.0.01&lt;/value&gt;
            &lt;value&gt;10.0.02&lt;/value&gt;
        &lt;/filter&gt;
    &lt;/filterSet&gt;
&lt;/includeFilterSets&gt;
&lt;/criteria&gt;
</code></pre>

<p>Result :</p>

<pre><code>&lt;bugs&gt;
    &lt;bug&gt;
        &lt;createdBy&gt;ashishg&lt;/createdBy&gt;
        &lt;dateCreated&gt;2011-12-16T09:19:45+05:30&lt;/dateCreated&gt;
        &lt;dateUpdated&gt;2011-12-16T09:19:45+05:30&lt;/dateUpdated&gt;
        &lt;dev&gt;dlaha&lt;/dev&gt;
        &lt;priority&gt;2&lt;/priority&gt;
        &lt;product&gt;Watson Express&lt;/product&gt;
        &lt;productArea&gt;Search New&lt;/productArea&gt;
        &lt;qe&gt;ashishg&lt;/qe&gt;
        &lt;reason&gt;
        &lt;/reason&gt;
        &lt;severity&gt;0&lt;/severity&gt;
        &lt;state&gt;Open&lt;/state&gt;
        &lt;status&gt;ToFix&lt;/status&gt;
        &lt;subArea&gt;
        &lt;/subArea&gt;
        &lt;title&gt;User should be able to navigate to the next bug when page limit is reached.&lt;/title&gt;
        &lt;updatedBy&gt;ashishg&lt;/updatedBy&gt;
        &lt;version&gt;4.0&lt;/version&gt;
        &lt;vulnerability&gt;N&lt;/vulnerability&gt;
    &lt;/bug&gt;
</code></pre>
