簡體   English   中英

碼頭沒開

[英]Jetty doesn't start

在開發過程中,我正在使用像應用服務器這樣的碼頭。 直到昨天一切正常,但是今天早晨當我嘗試執行jetty:run命令時,出現以下錯誤:

    2014-05-27 09:38:44.472:WARN::FAILED org.eclipse.jetty.server.handler.ContextHandlerCollection@1ec50ba: java.lang.NoClassDefFoundError: org/apache/poi/ss/usermodel/Workbook
    2014-05-27 09:38:44.473:WARN::FAILED org.eclipse.jetty.server.handler.HandlerCollection@1a81175: java.lang.NoClassDefFoundError: org/apache/poi/ss/usermodel/Workbook
    2014-05-27 09:38:44.484:INFO::Started SelectChannelConnector@0.0.0.0:8081 STARTING
    2014-05-27 09:38:44.484:WARN::FAILED org.mortbay.jetty.plugin.JettyServer@bd238b: java.lang.NoClassDefFoundError: org/apache/poi/ss/usermodel/Workbook
    [INFO] Jetty server exiting.
    [INFO] ------------------------------------------------------------------------
    [INFO] BUILD FAILURE
    [INFO] ------------------------------------------------------------------------
    [INFO] Total time: 8.782s
    [INFO] Finished at: Tue May 27 09:38:44 CEST 2014
    [INFO] Final Memory: 31M/74M
    [INFO] ------------------------------------------------------------------------
    [ERROR] Failed to execute goal org.mortbay.jetty:jetty-maven-plugin:7.4.2.v20110526:run (default-cli) on project vaadin-woe: Execution default-cli of goal org.mortbay.jetty:jetty-maven-plugin:7.4.2.v20110526:run failed: A required class was missing while executing org.mortbay.jetty:jetty-maven-plugin:7.4.2.v20110526:run: org/apache/poi/ss/usermodel/Workbook
    [ERROR] -----------------------------------------------------
    [ERROR] realm =    plugin>org.mortbay.jetty:jetty-maven-plugin:7.4.2.v20110526
    [ERROR] strategy = org.codehaus.plexus.classworlds.strategy.SelfFirstStrategy
    [ERROR] urls[0] = file:/C:/Users/myUser/.m2/repository/org/mortbay/jetty/jetty-maven-plugin/7.4.2.v20110526/jetty-maven-plugin-7.4.2.v20110526.jar
    [ERROR] urls[1] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-webapp/7.4.2.v20110526/jetty-webapp-7.4.2.v20110526.jar
    [ERROR] urls[2] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-xml/7.4.2.v20110526/jetty-xml-7.4.2.v20110526.jar
    [ERROR] urls[3] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-servlet/7.4.2.v20110526/jetty-servlet-7.4.2.v20110526.jar
    [ERROR] urls[4] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-security/7.4.2.v20110526/jetty-security-7.4.2.v20110526.jar
    [ERROR] urls[5] = file:/C:/Users/myUser/.m2/repository/org/codehaus/plexus/plexus-utils/1.4.6/plexus-utils-1.4.6.jar
    [ERROR] urls[6] = file:/C:/Users/myUser/.m2/repository/junit/junit/3.8.1/junit-3.8.1.jar
    [ERROR] urls[7] = file:/C:/Users/myUser/.m2/repository/org/apache/maven/plugin-tools/maven-plugin-tools-api/2.5.1/maven-plugin-tools-api-2.5.1.jar
    [ERROR] urls[8] = file:/C:/Users/myUser/.m2/repository/org/apache/maven/reporting/maven-reporting-api/2.0.6/maven-reporting-api-2.0.6.jar
    [ERROR] urls[9] = file:/C:/Users/myUser/.m2/repository/org/apache/maven/doxia/doxia-sink-api/1.0-alpha-7/doxia-sink-api-1.0-alpha-7.jar
    [ERROR] urls[10] = file:/C:/Users/myUser/.m2/repository/jtidy/jtidy/4aug2000r7-dev/jtidy-4aug2000r7-dev.jar
    [ERROR] urls[11] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-plus/7.4.2.v20110526/jetty-plus-7.4.2.v20110526.jar
    [ERROR] urls[12] = file:/C:/Users/myUser/.m2/repository/org/apache/geronimo/specs/geronimo-jta_1.1_spec/1.1.1/geronimo-jta_1.1_spec-1.1.1.jar
    [ERROR] urls[13] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-jndi/7.4.2.v20110526/jetty-jndi-7.4.2.v20110526.jar
    [ERROR] urls[14] = file:/C:/Users/myUser/.m2/repository/javax/mail/mail/1.4.1/mail-1.4.1.jar
    [ERROR] urls[15] = file:/C:/Users/myUser/.m2/repository/javax/activation/activation/1.1/activation-1.1.jar
    [ERROR] urls[16] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-jmx/7.4.2.v20110526/jetty-jmx-7.4.2.v20110526.jar
    [ERROR] urls[17] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-util/7.4.2.v20110526/jetty-util-7.4.2.v20110526.jar
    [ERROR] urls[18] = file:/C:/Users/myUser/.m2/repository/org/mortbay/jetty/jsp-2.1-glassfish/2.1.v20100127/jsp-2.1-glassfish-2.1.v20100127.jar
    [ERROR] urls[19] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jdt/core/compiler/ecj/3.5.1/ecj-3.5.1.jar
    [ERROR] urls[20] = file:/C:/Users/myUser/.m2/repository/org/mortbay/jetty/jsp-api-2.1-glassfish/2.1.v20100127/jsp-api-2.1-glassfish-2.1.v20100127.jar
    [ERROR] urls[21] = file:/C:/Users/myUser/.m2/repository/ant/ant/1.6.5/ant-1.6.5.jar
    [ERROR] urls[22] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-jsp-2.1/7.4.2.v20110526/jetty-jsp-2.1-7.4.2.v20110526.jar
    [ERROR] urls[23] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-annotations/7.4.2.v20110526/jetty-annotations-7.4.2.v20110526.jar
    [ERROR] urls[24] = file:/C:/Users/myUser/.m2/repository/org/apache/geronimo/specs/geronimo-annotation_1.0_spec/1.1.1/geronimo-annotation_1.0_spec-1.1.1.jar
    [ERROR] urls[25] = file:/C:/Users/myUser/.m2/repository/asm/asm-commons/3.1/asm-commons-3.1.jar
    [ERROR] urls[26] = file:/C:/Users/myUser/.m2/repository/asm/asm-tree/3.1/asm-tree-3.1.jar
    [ERROR] urls[27] = file:/C:/Users/myUser/.m2/repository/asm/asm/3.1/asm-3.1.jar
    [ERROR] urls[28] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-start/7.4.2.v20110526/jetty-start-7.4.2.v20110526.jar
    [ERROR] urls[29] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-websocket/7.4.2.v20110526/jetty-websocket-7.4.2.v20110526.jar
    [ERROR] urls[30] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-server/7.4.2.v20110526/jetty-server-7.4.2.v20110526.jar
    [ERROR] urls[31] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-continuation/7.4.2.v20110526/jetty-continuation-7.4.2.v20110526.jar
    [ERROR] urls[32] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-http/7.4.2.v20110526/jetty-http-7.4.2.v20110526.jar
    [ERROR] urls[33] = file:/C:/Users/myUser/.m2/repository/org/eclipse/jetty/jetty-io/7.4.2.v20110526/jetty-io-7.4.2.v20110526.jar
    [ERROR] urls[34] = file:/C:/Users/myUser/.m2/repository/javax/servlet/servlet-api/2.5/servlet-api-2.5.jar
    [ERROR] Number of foreign imports: 1
    [ERROR] import: Entry[import  from realm ClassRealm[maven.api, parent: null]]
    [ERROR] 
    [ERROR] -----------------------------------------------------: org.apache.poi.ss.usermodel.Workbook
    [ERROR] -> [Help 1]
    [ERROR] 
    [ERROR] To see the full stack trace of the errors, re-run Maven with the -e switch.
    [ERROR] Re-run Maven using the -X switch to enable full debug logging.
    [ERROR] 
    [ERROR] For more information about the errors and possible solutions, please read the following articles:
    [ERROR] [Help 1] http://cwiki.apache.org/confluence/display/MAVEN/PluginContainerException
    2014-05-27 09:38:45.092:INFO:/vaadin-woe:Shutting down log4j
    2014-05-27 09:38:45.096:INFO:/vaadin-woe:Closing Spring root WebApplicationContext

我以為該錯誤可能是某個損壞的jar,然后從本地存儲庫中刪除了以下文件夾:

org->eclipse->jetty
org->mortbay->jetty
org->apache->poi

前兩個已下載(從我的工件),而poi尚未下載,但出現上述錯誤。

如何解決此問題?

將插件放入pom中

然后使用mvn install

嘗試通過命令行通過mvn jetty:run

注意:大多數eclipse插件都存在一些問題

我的麻煩是poi的jar文件損壞。 由於我在模塊化項目中工作,因此poi依賴項是從服務模塊繼承的,因此刪除了本地存儲庫中的poi文件夾並重新安裝了服務模塊,因此我解決了所有問題

暫無
暫無

聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.

 
粵ICP備18138465號  © 2020-2024 STACKOOM.COM