SLOR error string field too large

65 views
Skip to first unread message

Jack OE

unread,
Jan 23, 2024, 2:09:09 AM1/23/24
to DSpace Technical Support
Hi all,

We've been encountering this error with SOLR in the past few days and I am wondering if anyone has any a solution for it, any help is greatly appreciated!

Remote error message: Exception writing document id Item-1739ff68-6dff-46ca-ad71-b8803a2a9137 to the index; possible analysis error: Document contains at least one immense term in field="bi_2_dis_prefix" (whose UTF8 encoding is longer than the max length 32766), all of which were skipped.  Please correct the analyzer to not produce such terms.  The prefix of the first immense term is: '[98, 114, 111, 119, 110, 44, 32, 112, 46, 59, 122, 104, 111, 117, 44, 32, 121, 46, 59, 116, 97, 110, 44, 32, 97, 46, 45, 99, 46, 59]...', original message: bytes can be at most 32766 in length; got 37865. Perhaps the document has an indexed string field (solr.StrField) which is too large
        at org.apache.solr.client.solrj.impl.HttpSolrClient.executeMethod(HttpSolrClient.java:681)
        at org.apache.solr.client.solrj.impl.HttpSolrClient.request(HttpSolrClient.java:266)
        at org.apache.solr.client.solrj.impl.HttpSolrClient.request(HttpSolrClient.java:248)
        at org.apache.solr.client.solrj.SolrRequest.process(SolrRequest.java:214)
        at org.apache.solr.client.solrj.SolrClient.add(SolrClient.java:177)
        at org.apache.solr.client.solrj.SolrClient.add(SolrClient.java:138)
        at org.apache.solr.client.solrj.SolrClient.add(SolrClient.java:156)
        at org.dspace.discovery.indexobject.IndexFactoryImpl.writeDocument(IndexFactoryImpl.java:151)
        at org.dspace.discovery.indexobject.ItemIndexFactoryImpl.writeDocument(ItemIndexFactoryImpl.java:752)
        at org.dspace.discovery.indexobject.ItemIndexFactoryImpl.writeDocument(ItemIndexFactoryImpl.java:81)
        at org.dspace.discovery.SolrServiceImpl.update(SolrServiceImpl.java:186)
        at org.dspace.discovery.SolrServiceImpl.indexContent(SolrServiceImpl.java:175)
        at org.dspace.discovery.SolrServiceImpl.updateIndex(SolrServiceImpl.java:365)
        at org.dspace.discovery.SolrServiceImpl.updateIndex(SolrServiceImpl.java:352)
        at org.dspace.discovery.SolrServiceImpl.createIndex(SolrServiceImpl.java:320)
        at org.dspace.discovery.IndexClient.internalRun(IndexClient.java:120)
        at org.dspace.scripts.DSpaceRunnable.run(DSpaceRunnable.java:150)
        at org.dspace.app.launcher.ScriptLauncher.executeScript(ScriptLauncher.java:174)
        at org.dspace.app.launcher.ScriptLauncher.handleScript(ScriptLauncher.java:151)
        at org.dspace.app.launcher.ScriptLauncher.handleScript(ScriptLauncher.java:125)
        at org.dspace.app.launcher.ScriptLauncher.main(ScriptLauncher.java:100)

Maruan Sahyoun

unread,
Jan 23, 2024, 5:12:57 AM1/23/24
to DSpace Technical Support
I'm wondering if the content is correct. Looks like you are trying to index content larger than 32766 but that's coming from the field bi_2_dis_prefix. Are you sure that the content in that field is correct.

To handle content larger than 32766 you need to change the field type in the Solr schema. It looks like you are using a string type to hold the data but string is limited in length. You can change to 'text' for example which allows to handle more data.

BR
Maruan
FileAffairs GmbH 
Reply all
Reply to author
Forward
Message has been deleted
0 new messages