Uploaded image for project: 'DSpace'
  1. DSpace
  2. DS-2703

missing items in Solr because field value started with left bracket "["

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Accepted / Claimed (View Workflow)
    • Priority: Minor
    • Resolution: Unresolved
    • Affects Version/s: 5.1, 5.3
    • Fix Version/s: None
    • Component/s: Solr
    • Labels:
    • Attachments:
      0
    • Comments:
      3
    • Documentation Status:
      Not Required

      Description

      This happened during import from CSV (via Batch Metadata Editor), but I imagine other import methods would be affected, too.

      Metadata fields in some of the records started with "[" (e.g. "[1936"). For all these records, the following error was thrown and no Solr document was created for the item, which resulted in wrong item counts in the collection / community hierarchy. The items can be displayed by typing in the URL, but cannot be found because they're missing from Solr.

      2015-08-13 16:10:59,353 ERROR org.dspace.discovery.SolrServiceImpl @ Error while writing item to discovery index: 123456789/26564 message:Error while creating field 'bata.citation.year

      {type=sint,properties=indexed,stored,omitNorms,omitTermFreqAndPositions,multiValued,sortMissingLast}' from value '[1936'
      org.apache.solr.client.solrj.impl.HttpSolrServer$RemoteSolrException: Error while creating field 'bata.citation.year{type=sint,properties=indexed,stored,omitNorms,omitTermFreqAndPositions,multiValued,sortMissingLast}

      ' from value '[1936'
      at org.apache.solr.client.solrj.impl.HttpSolrServer.executeMethod(HttpSolrServer.java:552)
      at org.apache.solr.client.solrj.impl.HttpSolrServer.request(HttpSolrServer.java:210)
      at org.apache.solr.client.solrj.impl.HttpSolrServer.request(HttpSolrServer.java:206)
      at org.apache.solr.client.solrj.request.AbstractUpdateRequest.process(AbstractUpdateRequest.java:124)
      at org.apache.solr.client.solrj.SolrServer.add(SolrServer.java:116)
      at org.apache.solr.client.solrj.SolrServer.add(SolrServer.java:102)
      at org.dspace.discovery.SolrServiceImpl.writeDocument(SolrServiceImpl.java:742)
      at org.dspace.discovery.SolrServiceImpl.buildDocument(SolrServiceImpl.java:1419)
      at org.dspace.discovery.SolrServiceImpl.indexContent(SolrServiceImpl.java:225)
      at org.dspace.discovery.IndexEventConsumer.end(IndexEventConsumer.java:170)
      at org.dspace.event.BasicDispatcher.dispatch(BasicDispatcher.java:147)
      at org.dspace.core.Context.commit(Context.java:390)
      at org.dspace.app.bulkedit.MetadataImport.main(MetadataImport.java:1409)
      at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
      at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:57)
      at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
      at java.lang.reflect.Method.invoke(Method.java:606)
      at org.dspace.app.launcher.ScriptLauncher.runOneCommand(ScriptLauncher.java:226)
      at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:78)

        Attachments

          Activity

            People

            Assignee:
            Unassigned
            Reporter:
            helix84 Ivan Masár
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

              Dates

              Created:
              Updated: