manifoldcf-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Jens Grassel (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (CONNECTORS-1243) Several NoClassDefFoundError error if web apps are deployed to tomcat
Date Tue, 29 Sep 2015 13:57:04 GMT

    [ https://issues.apache.org/jira/browse/CONNECTORS-1243?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14935201#comment-14935201
] 

Jens Grassel commented on CONNECTORS-1243:
------------------------------------------

Sorry for the late reply, I was travelling. I can run the war files if I follow your steps
from above. Therefore I guess I've messed up the configuration somehow.

If I deploy the war files from my build then I get the following error message in the logs:

{noformat}
 WARN 2015-09-29 13:51:12,382 (localhost-startStop-1) - Could not find connectorcommon main
class: org.apache.manifoldcf.connectorcommon.system.ManifoldCF
java.lang.ClassNotFoundException: org.apache.manifoldcf.connectorcommon.system.ManifoldCF
        at java.net.URLClassLoader.findClass(URLClassLoader.java:381)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:424)
        at java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:814)
        at java.lang.ClassLoader.loadClass(ClassLoader.java:357)
        at java.lang.Class.forName0(Native Method)
        at java.lang.Class.forName(Class.java:348)
        at org.apache.manifoldcf.core.system.ManifoldCFResourceLoader.findClass(ManifoldCFResourceLoader.java:149)
        at org.apache.manifoldcf.core.system.ManifoldCF.findClass(ManifoldCF.java:1496)
        at org.apache.manifoldcf.core.system.ManifoldCF.registerConnectorServices(ManifoldCF.java:318)
        at org.apache.manifoldcf.core.system.ManifoldCF.initializeEnvironment(ManifoldCF.java:287)
        at org.apache.manifoldcf.authorities.system.ManifoldCF.initializeEnvironment(ManifoldCF.java:56)
        at org.apache.manifoldcf.authorityservice.ServletListener.contextInitialized(ServletListener.java:36)
        at org.apache.catalina.core.StandardContext.listenerStart(StandardContext.java:4973)
        at org.apache.catalina.core.StandardContext.startInternal(StandardContext.java:5467)
        at org.apache.catalina.util.LifecycleBase.start(LifecycleBase.java:150)
        at org.apache.catalina.core.ContainerBase.addChildInternal(ContainerBase.java:901)
        at org.apache.catalina.core.ContainerBase.addChild(ContainerBase.java:877)
        at org.apache.catalina.core.StandardHost.addChild(StandardHost.java:632)
        at org.apache.catalina.startup.HostConfig.deployWAR(HostConfig.java:1073)
        at org.apache.catalina.startup.HostConfig$DeployWar.run(HostConfig.java:1857)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)
{noformat}

Maybe there is some classpath issue?


> Several NoClassDefFoundError error if web apps are deployed to tomcat
> ---------------------------------------------------------------------
>
>                 Key: CONNECTORS-1243
>                 URL: https://issues.apache.org/jira/browse/CONNECTORS-1243
>             Project: ManifoldCF
>          Issue Type: Bug
>    Affects Versions: ManifoldCF 2.2
>         Environment: Running on Ubuntu 14.04 LTS.
> {code}
> % java -version
> java version "1.8.0_51"
> Java(TM) SE Runtime Environment (build 1.8.0_51-b16)
> Java HotSpot(TM) 64-Bit Server VM (build 25.51-b03, mixed mode)
> % dpkg -l | grep tomcat
> ii  libtomcat7-java                     7.0.52-1ubuntu0.3                    all    
     Servlet and JSP engine -- core libraries
> ii  tomcat7                             7.0.52-1ubuntu0.3                    all    
     Servlet and JSP engine
> ii  tomcat7-admin                       7.0.52-1ubuntu0.3                    all    
     Servlet and JSP engine -- admin web applications
> ii  tomcat7-common                      7.0.52-1ubuntu0.3                    all    
     Servlet and JSP engine -- common files
> {code}
>            Reporter: Jens Grassel
>            Assignee: Karl Wright
>              Labels: classpath, crash, tomcat, ui
>
> Hi,
> I've just compiled the current 2.2 release using {{ant make-core-deps make-deps build}}
and deployed the 3 WAR files into a tomcat server. After running {{org.apache.manifoldcf.crawler.InitializeAndRegister}}
the database seemed to be populated and the web ui seemed workable.
> However, on certain occasions a {{java.lang.NoClassDefFoundError}} is thrown.
> I've looked into {{WEB-INF/lib}} and didn't find the needed classes in any of the jar
files there. On the other hand copying the jars into tomcats {{lib}}, {{common}} or {{shared}}
directories didn't help either. :-(
> Regards,
> Jens
> See below for two example to reproduce this error.
> h3. Creating a RSS repository connector
> Just give it a name, select the RSS type and continue:
> {noformat}
> HTTP Status 500 - An exception occurred processing JSP page /execute.jsp at line 148
> type Exception report
> message An exception occurred processing JSP page /execute.jsp at line 148
> description The server encountered an internal error that prevented it from fulfilling
this request.
> exception
> org.apache.jasper.JasperException: An exception occurred processing JSP page /execute.jsp
at line 148
> 145:             }
> 146:           }
> 147: 
> 148:           String error = RepositoryConnectorFactory.processConfigurationPost(threadContext,connection.getClassName(),variableContext,pageContext.getRequest().getLocale(),connection.getConfigParams());
> 149: 
> 150:           if (error != null)
> 151:           {
> Stacktrace:
> 	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/manifoldcf/connectorcommon/fuzzyml/XMLParsingContext
> 	org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:916)
> 	org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:845)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:2550)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> java.lang.NoClassDefFoundError: org/apache/manifoldcf/connectorcommon/fuzzyml/XMLParsingContext
> 	java.lang.Class.forName0(Native Method)
> 	java.lang.Class.forName(Class.java:348)
> 	org.apache.manifoldcf.core.system.ManifoldCFResourceLoader.findClass(ManifoldCFResourceLoader.java:149)
> 	org.apache.manifoldcf.core.system.ManifoldCF.findClass(ManifoldCF.java:1496)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.getThisConnectorRaw(ConnectorFactory.java:144)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.getThisConnector(ConnectorFactory.java:134)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.processThisConfigurationPost(ConnectorFactory.java:92)
> 	org.apache.manifoldcf.crawler.interfaces.RepositoryConnectorFactory.processConfigurationPost(RepositoryConnectorFactory.java:163)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:308)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> java.lang.ClassNotFoundException: org.apache.manifoldcf.connectorcommon.fuzzyml.XMLParsingContext
> 	java.net.URLClassLoader.findClass(URLClassLoader.java:381)
> 	java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> 	java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:814)
> 	java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> 	java.lang.Class.forName0(Native Method)
> 	java.lang.Class.forName(Class.java:348)
> 	org.apache.manifoldcf.core.system.ManifoldCFResourceLoader.findClass(ManifoldCFResourceLoader.java:149)
> 	org.apache.manifoldcf.core.system.ManifoldCF.findClass(ManifoldCF.java:1496)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.getThisConnectorRaw(ConnectorFactory.java:144)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.getThisConnector(ConnectorFactory.java:134)
> 	org.apache.manifoldcf.core.interfaces.ConnectorFactory.processThisConfigurationPost(ConnectorFactory.java:92)
> 	org.apache.manifoldcf.crawler.interfaces.RepositoryConnectorFactory.processConfigurationPost(RepositoryConnectorFactory.java:163)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:308)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> note The full stack trace of the root cause is available in the Apache Tomcat/7.0.52
(Ubuntu) logs.
> {noformat}
> h3. Create a Confluence repository connector
> Give it a name, select confluence, configure the connection and click save:
> {noformat}
> HTTP Status 500 - An exception occurred processing JSP page /execute.jsp at line 179
> type Exception report
> message An exception occurred processing JSP page /execute.jsp at line 179
> description The server encountered an internal error that prevented it from fulfilling
this request.
> exception
> org.apache.jasper.JasperException: An exception occurred processing JSP page /execute.jsp
at line 179
> 176:             connManager.save(connection);
> 177:             variableContext.setParameter("connname",connectionName);
> 178: %>
> 179:             <jsp:forward page="viewconnection.jsp"/>
> 180: <%
> 181:           }
> 182:         }
> Stacktrace:
> 	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> org.apache.jasper.JasperException: An exception occurred processing JSP page /viewconnection.jsp
at line 70
> 67:     String connectionStatus;
> 68:     try
> 69:     {
> 70:       IRepositoryConnector c = repositoryConnectorPool.grab(connection);
> 71:       if (c == null)
> 72:         connectionStatus = Messages.getString(pageContext.getRequest().getLocale(),"viewconnection.Connectorisnotinstalled");
> 73:       else
> Stacktrace:
> 	org.apache.jasper.servlet.JspServletWrapper.handleJspException(JspServletWrapper.java:568)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:455)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:750)
> 	org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:720)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:363)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> javax.servlet.ServletException: java.lang.NoClassDefFoundError: org/apache/manifoldcf/connectorcommon/common/InterruptibleSocketFactory
> 	org.apache.jasper.runtime.PageContextImpl.doHandlePageException(PageContextImpl.java:916)
> 	org.apache.jasper.runtime.PageContextImpl.handlePageException(PageContextImpl.java:845)
> 	org.apache.jsp.viewconnection_jsp._jspService(viewconnection_jsp.java:539)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:750)
> 	org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:720)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:363)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> java.lang.NoClassDefFoundError: org/apache/manifoldcf/connectorcommon/common/InterruptibleSocketFactory
> 	org.apache.manifoldcf.crawler.connectors.confluence.ConfluenceRepositoryConnector.initConfluenceClient(ConfluenceRepositoryConnector.java:295)
> 	org.apache.manifoldcf.crawler.connectors.confluence.ConfluenceRepositoryConnector.connect(ConfluenceRepositoryConnector.java:191)
> 	org.apache.manifoldcf.core.connectorpool.ConnectorPool$Pool.getConnector(ConnectorPool.java:479)
> 	org.apache.manifoldcf.core.connectorpool.ConnectorPool.grab(ConnectorPool.java:255)
> 	org.apache.manifoldcf.crawler.repositoryconnectorpool.RepositoryConnectorPool.grab(RepositoryConnectorPool.java:86)
> 	org.apache.jsp.viewconnection_jsp._jspService(viewconnection_jsp.java:237)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:750)
> 	org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:720)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:363)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> root cause
> java.lang.ClassNotFoundException: org.apache.manifoldcf.connectorcommon.common.InterruptibleSocketFactory
> 	java.net.URLClassLoader.findClass(URLClassLoader.java:381)
> 	java.lang.ClassLoader.loadClass(ClassLoader.java:424)
> 	java.net.FactoryURLClassLoader.loadClass(URLClassLoader.java:814)
> 	java.lang.ClassLoader.loadClass(ClassLoader.java:357)
> 	org.apache.manifoldcf.crawler.connectors.confluence.ConfluenceRepositoryConnector.initConfluenceClient(ConfluenceRepositoryConnector.java:295)
> 	org.apache.manifoldcf.crawler.connectors.confluence.ConfluenceRepositoryConnector.connect(ConfluenceRepositoryConnector.java:191)
> 	org.apache.manifoldcf.core.connectorpool.ConnectorPool$Pool.getConnector(ConnectorPool.java:479)
> 	org.apache.manifoldcf.core.connectorpool.ConnectorPool.grab(ConnectorPool.java:255)
> 	org.apache.manifoldcf.crawler.repositoryconnectorpool.RepositoryConnectorPool.grab(RepositoryConnectorPool.java:86)
> 	org.apache.jsp.viewconnection_jsp._jspService(viewconnection_jsp.java:237)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.runtime.PageContextImpl.doForward(PageContextImpl.java:750)
> 	org.apache.jasper.runtime.PageContextImpl.forward(PageContextImpl.java:720)
> 	org.apache.jsp.execute_jsp._jspService(execute_jsp.java:363)
> 	org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:70)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> 	org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:432)
> 	org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:390)
> 	org.apache.jasper.servlet.JspServlet.service(JspServlet.java:334)
> 	javax.servlet.http.HttpServlet.service(HttpServlet.java:727)
> note The full stack trace of the root cause is available in the Apache Tomcat/7.0.52
(Ubuntu) logs.
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Mime
View raw message