Code example for DefaultHttpClient

Methods: getParamssetHttpRequestRetryHandler

0
	} 
 
	private DefaultHttpClient configureHTTPClient(
			ThreadSafeClientConnManager connManager) {
		connManager.setDefaultMaxPerRoute(1000);
		DefaultHttpClient client = new DefaultHttpClient(connManager);
		HttpParams params = client.getParams();
		HttpConnectionParams.setConnectionTimeout(params, 30000);
		HttpConnectionParams.setSoTimeout(params, 30000);
		client.setHttpRequestRetryHandler(new HttpRequestRetryHandler() {
			public boolean retryRequest(IOException e, int i,
					HttpContext httpContext) {
				return false; 
			} 
		}); 
         
        System.out.println("<Security xmlns=\"http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd\" SOAP-ENV:mustUnderstand=\"1\">\n" +
                "            <UsernameToken>\n" + 
                "                <Username>yourName@t-online.de</Username>\n" + 
                "                <Password Type=\"http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-username-token-profile-1.0#PasswordText\">yourPassword</Password>\n" + 
Connect your IDE to all the code out there  Get Codota for Java