Hi I am new in Solr and using Solr 7.0.0 running in windows 7. The Solr is running in cloud mode. I created a collection and tried to index a list of pdf and html files residing in a folder using the following command:
> java -jar -Dc=guidanceDoc -Dauto example\exampledocs\post.jar M:\Projects\guidance\documents\*
The pdf files in my folder have no ".pdf" extension, however, the html files have htm extension.
While indexing using the above command, the pdf files are indexed without any error. However, during running the command, if the process gets an html file shows an error as follows:
> POSTing file ucm073837.htm (text/html) to [base]/extract
> SimplePostTool: WARNING: Solr returned an error #400 (Bad Request) for
> url: http
> ://localhost:8983/solr/guidanceDoc/update/extract?resource.name=M%3A%5CProjects%
> 5Cguidance%5Cdocuments%5Cucm073837.htm&literal.id=M%3A%5CProjects%5Cguidance%5Cd
> ocuments%5Cucm073837.htm SimplePostTool: WARNING: Response: {
> "responseHeader":{
> "status":400,
> "QTime":10}, "error":{
> "metadata":[
> "error-class","org.apache.solr.common.SolrException",
> "root-error-class","org.apache.solr.common.SolrException"],
> "msg":"Document contains multiple values for uniqueKey field: id=[M:\\Projec ts\\guidance\\documents\\ucm073837.htm, UCM073837]",
> "code":400}} SimplePostTool: WARNING: IOException while reading response: java.io.IOException : Server returned HTTP response code:
> 400 for URL: http://localhost:8983/solr/gu
> idanceDoc/update/extract?resource.name=M%3A%5CProjects%5Cguidance%5Cdocuments%5C
> ucm073837.htm&literal.id=M%3A%5CProjects%5Cguidance%5Cdocuments%5Cucm073837.htm
- How can I resolve this problem?