Project

General

Profile

Bug #7860

Solr index tool doesn't work

Added by Jing Tao almost 4 years ago. Updated almost 4 years ago.

Status:
Closed
Priority:
Normal
Assignee:
Category:
d1_indexer
Target version:
Start date:
2016-08-04
Due date:
% Done:

100%

Milestone:
None
Product Version:
*
Story Points:
Sprint:

Description

When I tried to reindex cn-dev, I got an error like:
Solr index refresh failed: Problem when serializing type 1
com.hazelcast.nio.HazelcastSerializationException: Problem when serializing type 1
at com.hazelcast.nio.AbstractSerializer.toObject(AbstractSerializer.java:128)
at com.hazelcast.nio.AbstractSerializer.toObject(AbstractSerializer.java:156)
at com.hazelcast.client.ClientThreadContext.toObject(ClientThreadContext.java:72)
at com.hazelcast.client.IOUtil.toObject(IOUtil.java:34)
at com.hazelcast.client.ProxyHelper.getValue(ProxyHelper.java:186)
at com.hazelcast.client.ProxyHelper.doOp(ProxyHelper.java:146)
at com.hazelcast.client.ProxyHelper.doOp(ProxyHelper.java:140)
at com.hazelcast.client.MapClientProxy.get(MapClientProxy.java:233)
at org.dataone.cn.utility.SolrIndexBuildTool.generateIndexTasksAndProcess(SolrIndexBuildTool.java:264)
at org.dataone.cn.utility.SolrIndexBuildTool.refreshSolrIndex(SolrIndexBuildTool.java:193)
at org.dataone.cn.utility.SolrIndexBuildTool.main(SolrIndexBuildTool.java:176)
Caused by: java.io.InvalidClassException: org.dataone.service.types.v1.AccessPolicy; local class incompatible: stream classdesc serialVersionUID = 6412946881539401262, local class serialVersionUID = 10000001
at java.io.ObjectStreamClass.initNonProxy(ObjectStreamClass.java:612)
at java.io.ObjectInputStream.readNonProxyDesc(ObjectInputStream.java:1630)
at java.io.ObjectInputStream.readClassDesc(ObjectInputStream.java:1521)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1779)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.defaultReadFields(ObjectInputStream.java:2016)
at java.io.ObjectInputStream.readSerialData(ObjectInputStream.java:1940)
at java.io.ObjectInputStream.readOrdinaryObject(ObjectInputStream.java:1806)
at java.io.ObjectInputStream.readObject0(ObjectInputStream.java:1353)
at java.io.ObjectInputStream.readUnshared(ObjectInputStream.java:463)
at com.hazelcast.nio.DefaultSerializer$ObjectSerializer.readNormal(DefaultSerializer.java:410)
at com.hazelcast.nio.DefaultSerializer$ObjectSerializer.read(DefaultSerializer.java:380)
at com.hazelcast.nio.DefaultSerializer.read(DefaultSerializer.java:138)
at com.hazelcast.nio.CustomSerializerAdapter.read(CustomSerializerAdapter.java:32)
at com.hazelcast.nio.AbstractSerializer.toObject(AbstractSerializer.java:121)
... 10 more
Exiting solr index refresh tool.

History

#1 Updated by Jing Tao almost 4 years ago

  • Status changed from New to Closed
  • % Done changed from 0 to 100

It turned out the serialVersionUID in the AccessPolicy class was changed from 10000000 to 10000001, then removed totally recently. However, the dependency of d1_cn_index_tool was still d1_common_java 2.2.0 snapshot which doesn't reflect the change. After I updated the dependency to 2.3.0 snapshot, it works.

I am wondering if we really don't want serial version uid in this class.

Also available in: Atom PDF

Add picture from clipboard (Maximum size: 14.8 MB)