Hello,

I am trying to integrate Lingo3g with Solr. I have arrived at the error 
ClassNotFoundException error using Lingo3g (verison 1.12.0) with Solr 4.8.0. I 
located the guava-18.0.jar, which contains the 
com.google.common.base.MoreObjects class, and have tried putting it in multiple 
locations within our Solr deployment, but have had no luck in getting by the 
error. So far, I have tried:

1)            Adding Class-Path: guava-18.0.jar to the manifest file in 
start.jar, solr.war and lingo3g-1.12.0.jar, with guava-18.0.jar copied to the 
same folder as each respective jar file.
2)            Putting guava-18.0.jar in the contrib\clustering\lib folder with 
the other lingo3g jar files.
3)            Putting guava-18.0.jar in the java jdk bin folder.

The stack trace I  get is:

java.lang.RuntimeException: java.lang.NoClassDefFoundError: 
com/google/common/base/MoreObjects at 
org.apache.solr.servlet.SolrDispatchFilter.sendError(SolrDispatchFilter.java:790)
 at 
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:439)
 at 
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:207)
 at 
org.eclipse.jetty.servlet.ServletHandler$CachedChain.doFilter(ServletHandler.java:1419)
 at org.eclipse.jetty.servlet.ServletHandler.doHandle(ServletHandler.java:455) 
at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:137) 
at org.eclipse.jetty.security.SecurityHandler.handle(SecurityHandler.java:557) 
at 
org.eclipse.jetty.server.session.SessionHandler.doHandle(SessionHandler.java:231)
 at 
org.eclipse.jetty.server.handler.ContextHandler.doHandle(ContextHandler.java:1075)
 at org.eclipse.jetty.servlet.ServletHandler.doScope(ServletHandler.java:384) 
at 
org.eclipse.jetty.server.session.SessionHandler.doScope(SessionHandler.java:193)
 at 
org.eclipse.jetty.server.handler.ContextHandler.doScope(ContextHandler.java:1009)
 at 
org.eclipse.jetty.server.handler.ScopedHandler.handle(ScopedHandler.java:135) 
at 
org.eclipse.jetty.server.handler.ContextHandlerCollection.handle(ContextHandlerCollection.java:255)
 at 
org.eclipse.jetty.server.handler.HandlerCollection.handle(HandlerCollection.java:154)
 at 
org.eclipse.jetty.server.handler.HandlerWrapper.handle(HandlerWrapper.java:116) 
at org.eclipse.jetty.server.Server.handle(Server.java:368) at 
org.eclipse.jetty.server.AbstractHttpConnection.handleRequest(AbstractHttpConnection.java:489)
 at 
org.eclipse.jetty.server.BlockingHttpConnection.handleRequest(BlockingHttpConnection.java:53)
 at 
org.eclipse.jetty.server.AbstractHttpConnection.headerComplete(AbstractHttpConnection.java:942)
 at 
org.eclipse.jetty.server.AbstractHttpConnection$RequestHandler.headerComplete(AbstractHttpConnection.java:1004)
 at org.eclipse.jetty.http.HttpParser.parseNext(HttpParser.java:640) at 
org.eclipse.jetty.http.HttpParser.parseAvailable(HttpParser.java:235) at 
org.eclipse.jetty.server.BlockingHttpConnection.handle(BlockingHttpConnection.java:72)
 at 
org.eclipse.jetty.server.bio.SocketConnector$ConnectorEndPoint.run(SocketConnector.java:264)
 at 
org.eclipse.jetty.util.thread.QueuedThreadPool.runJob(QueuedThreadPool.java:608)
 at 
org.eclipse.jetty.util.thread.QueuedThreadPool$3.run(QueuedThreadPool.java:543) 
at java.lang.Thread.run(Unknown Source) Caused by: 
java.lang.NoClassDefFoundError: com/google/common/base/MoreObjects at 
com.carrotsearch.lingo3g.impl.linguistic.model.Sequence$SequenceConverter.read(Unknown
 Source) at 
com.carrotsearch.lingo3g.impl.linguistic.model.Sequence$SequenceConverter.read(Unknown
 Source) at 
org.simpleframework.xml.convert.AnnotationStrategy.read(AnnotationStrategy.java:126)
 at 
org.simpleframework.xml.convert.AnnotationStrategy.read(AnnotationStrategy.java:105)
 at 
org.carrot2.util.simplexml.SessionInitStrategy.read(SessionInitStrategy.java:52)
 at org.simpleframework.xml.core.Source.getOverride(Source.java:360) at 
org.simpleframework.xml.core.Factory.getConversion(Factory.java:207) at 
org.simpleframework.xml.core.Factory.getOverride(Factory.java:139) at 
org.simpleframework.xml.core.ObjectFactory.getInstance(ObjectFactory.java:63) 
at org.simpleframework.xml.core.Composite.read(Composite.java:139) at 
org.simpleframework.xml.core.Composite.readVariable(Composite.java:623) at 
org.simpleframework.xml.core.Composite.readInstance(Composite.java:573) at 
org.simpleframework.xml.core.Composite.readUnion(Composite.java:549) at 
org.simpleframework.xml.core.Composite.readElement(Composite.java:532) at 
org.simpleframework.xml.core.Composite.readElements(Composite.java:445) at 
org.simpleframework.xml.core.Composite.access$400(Composite.java:59) at 
org.simpleframework.xml.core.Composite$Builder.read(Composite.java:1383) at 
org.simpleframework.xml.core.Composite.read(Composite.java:201) at 
org.simpleframework.xml.core.Composite.read(Composite.java:148) at 
org.simpleframework.xml.core.Traverser.read(Traverser.java:92) at 
org.simpleframework.xml.core.CompositeInlineList.read(CompositeInlineList.java:190)
 at 
org.simpleframework.xml.core.CompositeInlineList.read(CompositeInlineList.java:167)
 at 
org.simpleframework.xml.core.CompositeInlineList.read(CompositeInlineList.java:144)
 at org.simpleframework.xml.core.Composite.readVariable(Composite.java:619) at 
org.simpleframework.xml.core.Composite.readInstance(Composite.java:573) at 
org.simpleframework.xml.core.Composite.readUnion(Composite.java:549) at 
org.simpleframework.xml.core.Composite.readElement(Composite.java:532) at 
org.simpleframework.xml.core.Composite.readElements(Composite.java:445) at 
org.simpleframework.xml.core.Composite.access$400(Composite.java:59) at 
org.simpleframework.xml.core.Composite$Builder.read(Composite.java:1383) at 
org.simpleframework.xml.core.Composite.read(Composite.java:201) at 
org.simpleframework.xml.core.Composite.read(Composite.java:148) at 
org.simpleframework.xml.core.Traverser.read(Traverser.java:92) at 
org.simpleframework.xml.core.Persister.read(Persister.java:625) at 
org.simpleframework.xml.core.Persister.read(Persister.java:606) at 
org.simpleframework.xml.core.Persister.read(Persister.java:584) at 
org.simpleframework.xml.core.Persister.read(Persister.java:543) at 
org.simpleframework.xml.core.Persister.read(Persister.java:444) at 
org.carrot2.util.simplexml.PersisterHelpers.read(PersisterHelpers.java:87) at 
lingo3g.cp.a(Unknown Source) at lingo3g.bw.a(Unknown Source) at 
lingo3g.cq.a(Unknown Source) at lingo3g.cq.apply(Unknown Source) at 
org.carrot2.util.resource.ResourceCache.get(ResourceCache.java:74) at 
lingo3g.cp.a(Unknown Source) at lingo3g.ck.<init>(Unknown Source) at 
lingo3g.v.a(Unknown Source) at 
com.carrotsearch.lingo3g.Lingo3GClusteringAlgorithm.a(Unknown Source) at 
com.carrotsearch.lingo3g.Lingo3GClusteringAlgorithm.a(Unknown Source) at 
com.carrotsearch.lingo3g.Lingo3GClusteringAlgorithm$1.process(Unknown Source) 
at 
org.carrot2.text.clustering.MultilingualClustering.clusterByLanguage(MultilingualClustering.java:284)
 at 
org.carrot2.text.clustering.MultilingualClustering.process(MultilingualClustering.java:163)
 at com.carrotsearch.lingo3g.Lingo3GClusteringAlgorithm.process(Unknown Source) 
at org.carrot2.core.ControllerUtils.performProcessing(ControllerUtils.java:106) 
at org.carrot2.core.Controller.process(Controller.java:357) at 
org.carrot2.core.Controller.process(Controller.java:247) at 
org.apache.solr.handler.clustering.carrot2.CarrotClusteringEngine.cluster(CarrotClusteringEngine.java:245)
 at 
org.apache.solr.handler.clustering.ClusteringComponent.process(ClusteringComponent.java:164)
 at 
org.apache.solr.handler.component.SearchHandler.handleRequestBody(SearchHandler.java:218)
 at 
org.apache.solr.handler.RequestHandlerBase.handleRequest(RequestHandlerBase.java:135)
 at 
org.apache.solr.core.RequestHandlers$LazyRequestHandlerWrapper.handleRequest(RequestHandlers.java:241)
 at org.apache.solr.core.SolrCore.execute(SolrCore.java:1952) at 
org.apache.solr.servlet.SolrDispatchFilter.execute(SolrDispatchFilter.java:774) 
at 
org.apache.solr.servlet.SolrDispatchFilter.doFilter(SolrDispatchFilter.java:418)
 ... 26 more Caused by: java.lang.ClassNotFoundException: 
com.google.common.base.MoreObjects at java.net.URLClassLoader$1.run(Unknown 
Source) at java.net.URLClassLoader$1.run(Unknown Source) at 
java.security.AccessController.doPrivileged(Native Method) at 
java.net.URLClassLoader.findClass(Unknown Source) at 
java.lang.ClassLoader.loadClass(Unknown Source) at 
java.net.FactoryURLClassLoader.loadClass(Unknown Source) at 
java.lang.ClassLoader.loadClass(Unknown Source) ... 90 more


Any thoughts you might have would be greatly appreciated. Note that we had 
clustering working with the free version that comes packaged with Solr.

Thanks in advance,
Collin

Reply via email to