lucene-solr-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Songtao Zheng <zhengsongtaon...@gmail.com>
Subject Solr Realtime Get RemoteSolrException: Expected mime type application/xml but got text/html
Date Fri, 06 Jun 2014 20:11:24 GMT
Solr version on remote server: solr-4.3.1 I am trying to use Solr Realtime
Get <http://wiki.apache.org/solr/RealTimeGet> to retrieve document before
commit. My code

class Test3
{
  static main(args)
  {
    def test = new Test3()
    test.run()
  }

  private run()
  {
    String url = "DEV_SERVER:8983/solr/emr"

    HttpSolrServer solr = new HttpSolrServer(url)

    SolrQuery q = new SolrQuery();
    q.setRequestHandler("/get");
    q.set("rid",
"6662c0f2.ee6a64fe.588j6qohe.9kd087u.0r00dg.6kr5pc2as0qu9m4ibr7f7");

    QueryRequest req = new QueryRequest(q);
    req.setResponseParser(new BinraryResponseParser());

    println "=============================================="
    rsp = req.process(solr);    // ERROR
  }
}

*The error stacktrace is:*
Caught:
org.apache.solr.client.solrj.impl.HttpSolrServer$RemoteSolrException:
Expected mime type application/octet-stream but got
text/html. <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
<title>Error 404 Not Found</title>
</head>
<body><h2>HTTP ERROR 404</h2>
<p>Problem accessing /solr/emr/get. Reason:
<pre>    Not Found</pre></p><hr /><i><small>Powered by
Jetty://</small></i><br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>

</body>
</html>

org.apache.solr.client.solrj.impl.HttpSolrServer$RemoteSolrException:
Expected mime type application/octet-stream but got text/htm
l. <html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
<title>Error 404 Not Found</title>
</head>
<body><h2>HTTP ERROR 404</h2>
<p>Problem accessing /solr/emr/get. Reason:
<pre>    Not Found</pre></p><hr /><i><small>Powered by
Jetty://</small></i><br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>
<br/>

</body>
</html>

        at
org.apache.solr.client.solrj.impl.HttpSolrServer.request(HttpSolrServer.java:459)
        at
org.apache.solr.client.solrj.impl.HttpSolrServer.request(HttpSolrServer.java:199)
        at
org.apache.solr.client.solrj.request.QueryRequest.process(QueryRequest.java:91)
        at
org.apache.solr.client.solrj.request.QueryRequest$process.call(Unknown
Source)
        at com.att.songtao.test.Test3.run(Test3.groovy:48)
        at com.att.songtao.test.Test3.this$2$run(Test3.groovy)
        at com.att.songtao.test.Test3$this$2$run.call(Unknown Source)
        at com.att.songtao.test.Test3.main(Test3.groovy:14)


I am following Realtime Get document and added updateLog to updateHandler
in solrconfig.xml. My localhost "localhost:8983/solr/emr" (version
solr-4.7.2) Realtime Get works perfect, but having it on remote server
throws out the above error.

Anyone could provide the insight?

Thanks,

Songtao

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message