Solr appears to force your UniqueKey field to be required even though you
don't have an explicit required="true" attribute.
As a debugging aid, try adding default="missing" to your "id" field
definition and then you can query on "id:missing" and see what data is being
indexed without an id. But, it would be better to examine the input data and
see why it is missing the id field, since that is the real problem that
needs to be resolved.
-- Jack Krupansky
-----Original Message-----
From: Tolga
Sent: Monday, May 21, 2012 6:07 AM
To: solr-user@lucene.apache.org
Subject: org.apache.solr.common.SolrException: ERROR: [doc=null] missing
required field: id
Hi,
I am getting this error:
[doc=null] missing required field: id
request: http://localhost:8983/solr/update?wt=javabin&version=2
at
org.apache.solr.client.solrj.impl.CommonsHttpSolrServer.request(CommonsHttpSolrServer.java:430)
at
org.apache.solr.client.solrj.impl.CommonsHttpSolrServer.request(CommonsHttpSolrServer.java:244)
at
org.apache.solr.client.solrj.request.AbstractUpdateRequest.process(AbstractUpdateRequest.java:105)
at org.apache.solr.client.solrj.SolrServer.add(SolrServer.java:49)
at org.apache.nutch.indexer.solr.SolrWriter.close(SolrWriter.java:93)
at
org.apache.nutch.indexer.IndexerOutputFormat$1.close(IndexerOutputFormat.java:48)
at
org.apache.hadoop.mapred.ReduceTask.runOldReducer(ReduceTask.java:474)
at org.apache.hadoop.mapred.ReduceTask.run(ReduceTask.java:411)
at
org.apache.hadoop.mapred.LocalJobRunner$Job.run(LocalJobRunner.java:216)
2012-05-21 11:44:29,953 ERROR solr.SolrIndexer - java.io.IOException:
Job failed!
I've got this entry in schema.xml: <field name="id" type="string"
stored="true" indexed="true"/>
What to do?
Regards,