: data). I given the prepared url in URL calss i got the HTTP Version Not : Supported and the error code is 505.
Solr never generates that error code. what servlet container are you using? : String urlStr = solrUrl + "/update?stream.body=" + strToAdd; : System.out.println(".....................SOLR_SERVER_URL: " + urlStr); : URL indexUrl = new URL(urlStr); : HttpURLConnection indexConnection = (HttpURLConnection) : indexUrl.openConnection(); : indexConnection.setRequestMethod("POST"); : indexConnection.connect(); this is a wild shot in the dark here about what might be causing your problem, but you are creating a POST request without actually POSTing anything (the stream.body param is a hack to let you send data as a URL param, if you are putting it in the URL args you don't need POST, but if you're sending data programaticly like this you might as well just use POST If SolrJ won't work for you, at least look at the code for SimplePostTool as an example of how to POST data to solr. -Hoss