0

我已经按照以下IBM Social Business Toolkit SDK Development Environment Setup Youtube 视频中的描述设置了 Java EE Eclipse ,我在IBM SBTSDK 的 OpenNTF.org 页面上找到了该视频。IBM Social Business Toolkit SDK 开发环境设置

当我启动 Tomcat 并打开 sbt.sample.web 并调用其中一个示例时,我在 Tomcat 日志中收到以下错误(见下文)。

我使用以下版本的 SBTSDK sbtsdk-1.0.0.20130228-2321。

以下项目在我的工作区中也有错误,无法构建描述资源路径位置类型项目“com.ibm.sbt.bootstrap211”缺少所需的源文件夹:“src”com.ibm.sbt.bootstrap211 构建路径构建路径问题

任何想法出了什么问题?

    INFO: Server startup in 2190 ms
05.04.2013 11:30:55 com.ibm.sbt.jslibrary.servlet.LibraryServlet doGet
WARNUNG: Error servicing library GET request
java.lang.NoClassDefFoundError: org/apache/http/HttpRequestInterceptor
    at java.lang.Class.getDeclaredConstructors0(Native Method)
    at java.lang.Class.privateGetDeclaredConstructors(Unknown Source)
    at java.lang.Class.getConstructor0(Unknown Source)
    at java.lang.Class.newInstance0(Unknown Source)
    at java.lang.Class.newInstance(Unknown Source)
    at com.ibm.commons.runtime.beans.AbstractBeanFactory$Factory.create(AbstractBeanFactory.java:65)
    at com.ibm.commons.runtime.impl.AbstractContext.getBean(AbstractContext.java:142)
    at com.ibm.sbt.services.endpoints.EndpointFactory.getEndpointUnchecked(EndpointFactory.java:87)
    at com.ibm.sbt.services.endpoints.EndpointFactory.getEndpointUnchecked(EndpointFactory.java:68)
    at com.ibm.sbt.jslibrary.servlet.AbstractLibrary.populateEndpoints(AbstractLibrary.java:237)
    at com.ibm.sbt.jslibrary.servlet.AbstractLibrary.doGet(AbstractLibrary.java:168)
    at com.ibm.sbt.jslibrary.servlet.LibraryServlet.doGet(LibraryServlet.java:170)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:621)
    at javax.servlet.http.HttpServlet.service(HttpServlet.java:722)
    at com.ibm.commons.runtime.servlet.BaseToolkitServlet.service(BaseToolkitServlet.java:100)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:305)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
    at com.ibm.sbt.util.SBTFilter.doFilter(SBTFilter.java:53)
    at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:243)
    at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:210)
    at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:222)
    at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:123)
    at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:472)
    at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:168)
    at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:99)
    at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:929)
    at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:118)
    at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:407)
    at org.apache.coyote.http11.AbstractHttp11Processor.process(AbstractHttp11Processor.java:1002)
    at org.apache.coyote.AbstractProtocol$AbstractConnectionHandler.process(AbstractProtocol.java:585)
    at org.apache.tomcat.util.net.JIoEndpoint$SocketProcessor.run(JIoEndpoint.java:312)
    at java.util.concurrent.ThreadPoolExecutor$Worker.runTask(Unknown Source)
    at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source)
    at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.ClassNotFoundException: org.apache.http.HttpRequestInterceptor
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1714)
    at org.apache.catalina.loader.WebappClassLoader.loadClass(WebappClassLoader.java:1559)
    ... 34 more
4

2 回答 2

0

对于项目 'com.ibm.sbt.bootstrap211' 缺少所需的源文件夹:

右键单击 bootstrap211 项目 > 属性 > Java 构建路径 > 单击源选项卡 > 取消选中“/src”(如果已选择)

于 2013-04-08T14:14:25.717 回答
0

从您得到的异常 ( java.lang.ClassNotFoundException: org.apache.http.HttpRequestInterceptor) 看来,您需要将httpcorejar 库包含到您的 Tomcat 中。

于 2013-04-05T13:28:37.697 回答