solrj 7.x Expected mime type application/octet-stream but got text/html.

出现这种情况是因为baseurl填写错误,最开始的时候我写的是用tomcat启动后浏览器中访问solr的地址

结果就出现了如题的异常,当然提示的是404,还有可能提示405,Method not allowed,method post is not supported等等

查看源码后发现给出的实例是这种格式http://ip:port/solr/+core,修改后重新测试正常

猜你喜欢

转载自www.cnblogs.com/tele-share/p/9226783.html