问题解决方法:Servlet: "testREST" failed to preload on startup in Web application: "claimInvoice".

问题描述:用jersey REST ful写的webservice接口项目,在window下JDK1.6032,weblogic10环境下,可以正常编译和部署。但是部署到Linux(CentOS 7)环境后,命令启动weblogic时候提示如下错误:java.lang.NoSuchMethodError: accept。也就是项目预加载未成功。在weblogic的console控制台也是报此错误。...
摘要由CSDN通过智能技术生成

问题描述:用jersey REST ful写的webservice接口项目,在window下JDK1.6032,weblogic10环境下,可以正常编译和部署。但是部署到Linux(CentOS 7)环境后,命令启动weblogic时候提示如下错误:java.lang.NoSuchMethodError: accept。也就是项目预加载未成功。在weblogic的console控制台也是报此错误。请各位大神看看这个错误原因和解决办法,万分感谢。

测试程序首页,提示Error 503--Service Unavailable错。

错误日志如下:

Enter username to boot WebLogic server:weblogic
Enter password to boot WebLogic server:
<Aug 20, 2018 3:38:25 AM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
<Aug 20, 2018 3:38:25 AM CST> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool>
<Aug 20, 2018 3:38:26 AM CST> <Notice> <Log Management> <BEA-170019> <The server log file /root/Oracle/Middleware/user_projects/domains/base_domain/servers/AdminServer/logs/AdminServer.log is opened. All server side log events will be written to this file.>
<Aug 20, 2018 3:38:30 AM CST> <Notice> <Security> <BEA-090082> <Security initializing using security realm myrealm.>
<Aug 20, 2018 3:38:53 AM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY>
<Aug 20, 2018 3:38:53 AM CST> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
<Aug 20, 2018 3:38:59 AM CST> <Warning> <HTTP> <BEA-101339> <The context parameter: weblogic.httpd.inputCharset./* has been deprecated. Instead use the element: charset-params in weblogic.xml.>
<Aug 20, 2018 3:38:59 AM CST> <Warning> <HTTP> <BEA-101369> <ServletContext@53278151[app:claimInvoice module:claimInvoice path:/claimInvoice spec-version:null]: The encoding jsp-descriptor param has been deprecated. Consider declaring the encoding in the jsp-config element (web.xml) or as a page directive (pageEncoding) instead.>
Aug 20, 2018 3:39:02 AM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Initializing Sun's JavaServer Faces implementation (1.2_03-b04-FCS) for context '/console'
Aug 20, 2018 3:39:02 AM com.sun.faces.config.ConfigureListener contextInitialized
INFO: Completed initializing Sun's JavaServer Faces implementation (1.2_03-b04-FCS) for context '/console'
log4j:WARN No appenders could be found for logger (org.directwebremoting.util.Logger).
log4j:WARN Please initialize the log4j system properly.
Aug 20, 2018 3:39:04 AM com.sun.jersey.api.core.PackagesResourceConfig init
INFO: Scanning for root resource and provider classes in the packages:
  com.sinosoft.claimCar.restful.service
<Aug 20, 2018 3:39:04 AM CST> <Error> <HTTP> <BEA-101216> <Servlet: "testREST" failed to preload on startup in Web application: "claimInvoice".
java.lang.NoSuchMethodError: accept
        at com.sun.jersey.spi.scanning.AnnotationScannerListener.onProcess(AnnotationScannerListener.java:138)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner$1.f(FileSchemeScanner.java:86)
        at com.sun.jersey.core.util.Closing.f(Closing.java:71)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:83)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:80)
        Truncated. see log file for complete stacktrace
>
<Aug 20, 2018 3:39:04 AM CST> <Error> <Deployer> <BEA-149231> <Unable to set the activation state to true for the application 'claimInvoice'.
weblogic.application.ModuleException: [HTTP:101216]Servlet: "testREST" failed to preload on startup in Web application: "claimInvoice".
java.lang.NoSuchMethodError: accept
        at com.sun.jersey.spi.scanning.AnnotationScannerListener.onProcess(AnnotationScannerListener.java:138)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner$1.f(FileSchemeScanner.java:86)
        at com.sun.jersey.core.util.Closing.f(Closing.java:71)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:83)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scanDirectory(FileSchemeScanner.java:80)
        at com.sun.jersey.core.spi.scanning.uri.FileSchemeScanner.scan(FileSchemeScanner.java:71)
        at com.sun.jersey.core.spi.scanning.PackageNamesScanner.scan(PackageNamesScanner.java:226)
        a

  • 1
    点赞
  • 1
    收藏
    觉得还不错? 一键收藏
  • 0
    评论

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值