ieb/solr — Issue #78: Exception when starting EmbeddedSolrClient (new server, old data)
Author: thecarlhall
Created: 2011-11-16 00:24:05+00:00
State: open

We're seeing the stacktrace below when an oae-1.1-SNAPSHOT server is started on data from an oae 1.0.2 server. I'm not sure if this is a Solr regression that might be fixed in some code later than our snapshot. I tested with the last code from ieb/solr/master and still get the exception, but because of code changes, the service is able to reach 'active' state.

Steps to reproduce:
1) Start oae 1.0.2 server (http://home.hallwaytech.com/org.sakaiproject.nakamura.app-1.0.2.jar)
2) Add users, groups, messages; things to trigger indexing. I used `rake setup` from the OAE Builder project.
3) Shutdown server. Delete sling/felix and sling/startup. Copy logs if wanted (optional).
4) Start oae 1.1-SNAPSHOT server using the same data (http://home.hallwaytech.com/org.sakaiproject.nakamura.app-1.1-SNAPSHOT.jar)

In the latest code, the EmbeddedSolrClient.java:131 is now at EmbeddedSolrClient.java:144[1]

https://github.com/ieb/solr/blob/master/src/main/java/org/sakaiproject/nakamura/solr/EmbeddedSolrClient.java#L144

15.11.2011 18:57:24.697 *INFO* [1385179278@qtp-2634125-0] org.sakaiproject.nakamura.solr.EmbeddedSolrClient Configuring with Config solrconfig.xml schema schema.xml
15.11.2011 18:59:15.879 *ERROR* [1385179278@qtp-2634125-0] org.sakaiproject.nakamura.solr [org.sakaiproject.nakamura.solr.EmbeddedSolrClient] The activate method has thrown an exception (java.lang.RuntimeException: java.io.IOException: read past EOF) java.lang.RuntimeException: java.io.IOException: read past EOF
at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1137)
at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:997)
at org.apache.solr.core.SolrCore.(SolrCore.java:601)
at org.apache.solr.core.SolrCore.(SolrCore.java:507)
at org.sakaiproject.nakamura.solr.EmbeddedSolrClient.activate(EmbeddedSolrClient.java:131)
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:616)
at org.apache.felix.scr.impl.helper.BaseMethod.invokeMethod(BaseMethod.java:227)
at org.apache.felix.scr.impl.helper.BaseMethod.access$500(BaseMethod.java:38)
at org.apache.felix.scr.impl.helper.BaseMethod$Resolved.invoke(BaseMethod.java:591)
at org.apache.felix.scr.impl.helper.BaseMethod.invoke(BaseMethod.java:472)
at org.apache.felix.scr.impl.helper.ActivateMethod.invoke(ActivateMethod.java:146)
at org.apache.felix.scr.impl.manager.ImmediateComponentManager.createImplementationObject(ImmediateComponentManager.java:226)
at org.apache.felix.scr.impl.manager.ImmediateComponentManager.createComponent(ImmediateComponentManager.java:118)
at org.apache.felix.scr.impl.manager.AbstractComponentManager$Unsatisfied.activate(AbstractComponentManager.java:997)
at org.apache.felix.scr.impl.manager.AbstractComponentManager.activateInternal(AbstractComponentManager.java:333)
at org.apache.felix.scr.impl.manager.AbstractComponentManager.enable(AbstractComponentManager.java:157)
at org.apache.felix.webconsole.internal.compendium.ComponentsServlet.doPost(ComponentsServlet.java:109)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:437)
at org.apache.felix.webconsole.internal.servlet.OsgiManager.service(OsgiManager.java:384)
at org.apache.felix.http.base.internal.handler.ServletHandler.doHandle(ServletHandler.java:96)
at org.apache.felix.http.base.internal.handler.ServletHandler.handle(ServletHandler.java:79)
at org.apache.felix.http.base.internal.dispatch.ServletPipeline.handle(ServletPipeline.java:42)
at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:49)
at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
at org.sakaiproject.nakamura.http.cache.CacheControlFilter.doFilter(CacheControlFilter.java:178)
at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:88)
at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:76)
at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:47)
at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
at org.sakaiproject.nakamura.http.usercontent.SafeHostFilter.doFilter(SafeHostFilter.java:87)
at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:88)
at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:76)
at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:47)
at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
at org.sakaiproject.nakamura.http.qos.QoSFilter.doFilter(QoSFilter.java:165)
at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:88)
at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:76)
at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:47)
at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
at org.mortbay.servlet.UserAgentFilter.doFilter(UserAgentFilter.java:78)
at org.sakaiproject.nakamura.jetty.GzipFilter.doFilter(GzipFilter.java:152)
at org.sakaiproject.nakamura.jetty.OSGiGZipFilter.doFilter(OSGiGZipFilter.java:50)
at org.apache.felix.http.base.internal.handler.FilterHandler.doHandle(FilterHandler.java:88)
at org.apache.felix.http.base.internal.handler.FilterHandler.handle(FilterHandler.java:76)
at org.apache.felix.http.base.internal.dispatch.InvocationFilterChain.doFilter(InvocationFilterChain.java:47)
at org.apache.felix.http.base.internal.dispatch.HttpFilterChain.doFilter(HttpFilterChain.java:33)
at org.apache.felix.http.base.internal.dispatch.FilterPipeline.dispatch(FilterPipeline.java:48)
at org.apache.felix.http.base.internal.dispatch.Dispatcher.dispatch(Dispatcher.java:39)
at org.apache.felix.http.base.internal.DispatcherServlet.service(DispatcherServlet.java:67)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:820)
at org.mortbay.jetty.servlet.ServletHolder.handle(ServletHolder.java:511)
at org.mortbay.jetty.servlet.ServletHandler.handle(ServletHandler.java:390)
at org.mortbay.jetty.servlet.SessionHandler.handle(SessionHandler.java:182)
at org.mortbay.jetty.handler.ContextHandler.handle(ContextHandler.java:765)
at org.mortbay.jetty.handler.HandlerWrapper.handle(HandlerWrapper.java:152)
at org.mortbay.jetty.Server.handle(Server.java:326)
at org.mortbay.jetty.HttpConnection.handleRequest(HttpConnection.java:542)
at org.mortbay.jetty.HttpConnection$RequestHandler.content(HttpConnection.java:943)
at org.mortbay.jetty.HttpParser.parseNext(HttpParser.java:756)
at org.mortbay.jetty.HttpParser.parseAvailable(HttpParser.java:218)
at org.mortbay.jetty.HttpConnection.handle(HttpConnection.java:404)
at org.mortbay.io.nio.SelectChannelEndPoint.run(SelectChannelEndPoint.java:410)
at org.mortbay.thread.QueuedThreadPool$PoolThread.run(QueuedThreadPool.java:582)
Caused by: java.io.IOException: read past EOF
at org.apache.lucene.store.BufferedIndexInput.refill(BufferedIndexInput.java:231)
at org.apache.lucene.store.BufferedIndexInput.readBytes(BufferedIndexInput.java:134)
at org.apache.lucene.store.BufferedIndexInput.readBytes(BufferedIndexInput.java:109)
at org.apache.lucene.store.ChecksumIndexInput.readBytes(ChecksumIndexInput.java:48)
at org.apache.lucene.store.DataInput.readString(DataInput.java:168)
at org.apache.lucene.store.DataInput.readStringStringMap(DataInput.java:196)
at org.apache.lucene.index.SegmentInfo.(SegmentInfo.java:232)
at org.apache.lucene.index.codecs.DefaultSegmentInfosReader.read(DefaultSegmentInfosReader.java:64)
at org.apache.lucene.index.SegmentInfos.read(SegmentInfos.java:258)
at org.apache.lucene.index.DirectoryReader$1.doBody(DirectoryReader.java:88)
at org.apache.lucene.index.SegmentInfos$FindSegmentsFile.run(SegmentInfos.java:699)
at org.apache.lucene.index.DirectoryReader.open(DirectoryReader.java:84)
at org.apache.lucene.index.IndexReader.open(IndexReader.java:496)
at org.apache.lucene.index.IndexReader.open(IndexReader.java:455)
at org.apache.solr.core.StandardIndexReaderFactory.newReader(StandardIndexReaderFactory.java:38)
at org.apache.solr.search.SolrIndexSearcher.(SolrIndexSearcher.java:144)
at org.apache.solr.core.SolrCore.getSearcher(SolrCore.java:1127)
... 67 more