即使在安装m2e + DWM之后,Eclipse Indigo SR2 EE中也没有Maven菜单项

时间:2012-05-31 08:51:56

标签: eclipse maven m2eclipse m2e

我安装了Eclipse Indigo SR2 EE:

Eclipse Java EE IDE for Web Developers.
Version: Indigo Service Release 2 
Build id: 20120216-1857

甚至在从Marketplace安装m2e后,我在File-> Import,File-> New-> Project ...,或Window-> Preferences中没有任何Maven菜单项。

我真的很困惑。我在Fedora 17 x64机器上运行 - 而我的其他 Fedora 17 x64机器在使用相同版本的Eclipse时工作正常!

m2e清楚地显示在“已安装的软件”中:

  m2e - Maven Integration for Eclipse   1.0.200.20111228-1245   org.eclipse.m2e.feature.feature.group   Eclipse.org - m2e

...并显示在配置报告中。然而,它在UI中完全不可见,它让我疯狂。

更新:错误日志中有些内容可能很重要 - 至少,它与m2e相关。请参阅帖子末尾附近的-consolelog here或缩写粘贴。

我对Eclipse很陌生,所以我可能做了一些愚蠢的事 - 但不管它是什么,Eclipse可以让它更明显是什么问题。

这与"Eclipse Indigo for JAVA EE + Maven plugin = the Maven menu does not appear in import and preference"不同;他们的m2e没有正确安装,这显示为已安装,Eclipse将不会重新安装,因为它已经安装,因此在“安装新软件......”中显示为灰色。

从命令行启动Eclipse时,stdout / stderr上不会发出错误。

我正在使用:

java -version
java version "1.7.0_b147-icedtea"
OpenJDK Runtime Environment (fedora-2.1.fc17.6-x86_64)
OpenJDK 64-Bit Server VM (build 22.0-b10, mixed mode)

在工作站上工作正常。 ls -d plugins/*m2e*显示:

plugins/org.eclipse.m2e.archetype.common_1.0.200.20111228-1245           plugins/org.eclipse.m2e.logback.appender_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.core_1.0.200.20111228-1245.jar                   plugins/org.eclipse.m2e.logback.configuration_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.core.ui_1.0.200.20111228-1245.jar                plugins/org.eclipse.m2e.maven.indexer_1.0.200.20111228-1245
plugins/org.eclipse.m2e.discovery_1.0.200.20111228-1245.jar              plugins/org.eclipse.m2e.maven.runtime_1.0.200.20111228-1245
plugins/org.eclipse.m2e.editor_1.0.200.20111228-1245.jar                 plugins/org.eclipse.m2e.model.edit_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.editor.xml_1.0.200.20111228-1245.jar             plugins/org.eclipse.m2e.refactoring_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.jdt_1.0.200.20111228-1245.jar                    plugins/org.eclipse.m2e.scm_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.launching_1.0.200.20111228-1245.jar              plugins/org.eclipse.m2e.usagedata_1.0.200.20111228-1245.jar
plugins/org.eclipse.m2e.lifecyclemapping.defaults_1.0.200.20111228-1245  plugins/org.sonatype.m2e.mavenarchiver_0.15.0.201109290002.jar

可能很重要的-consolelog错误:

16:58:08,042 |-ERROR in ch.qos.logback.core.joran.action.NestedComplexPropertyIA - Could not create component [filter] of type [org.eclipse.m2e.logback.appender.ConsoleAppenderFilter] java.lang.ClassNotFoundException: org.eclipse.m2e.logback.appender.ConsoleAppenderFilter
        at java.lang.ClassNotFoundException: org.eclipse.m2e.logback.appender.ConsoleAppenderFilter
        at      at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
        at      at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
        at      at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
        at      at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
        at      at java.lang.ClassLoader.loadClass(ClassLoader.java:356)
        at      at ch.qos.logback.core.util.Loader.loadClass(Loader.java:110)
        at      at ch.qos.logback.core.joran.action.NestedComplexPropertyIA.begin(NestedComplexPropertyIA.java:100)
        at      at ch.qos.logback.core.joran.spi.Interpreter.callBeginAction(Interpreter.java:273)
        at      at ch.qos.logback.core.joran.spi.Interpreter.startElement(Interpreter.java:145)
        at      at ch.qos.logback.core.joran.spi.Interpreter.startElement(Interpreter.java:127)
        at      at ch.qos.logback.core.joran.spi.EventPlayer.play(EventPlayer.java:40)
        at      at ch.qos.logback.core.joran.spi.Interpreter.play(Interpreter.java:332)
        at      at ch.qos.logback.core.joran.GenericConfigurator.doConfigure(GenericConfigurator.java:126)
        at      at ch.qos.logback.core.joran.GenericConfigurator.doConfigure(GenericConfigurator.java:93)
        at      at ch.qos.logback.core.joran.GenericConfigurator.doConfigure(GenericConfigurator.java:52)
        at      at org.eclipse.m2e.logback.configuration.LogPlugin.loadConfiguration(LogPlugin.java:190)
        at      at org.eclipse.m2e.logback.configuration.LogPlugin.configureLogback(LogPlugin.java:149)
        at      at org.eclipse.m2e.logback.configuration.LogPlugin.access$2(LogPlugin.java:112)
        at      at org.eclipse.m2e.logback.configuration.LogPlugin$1.run(LogPlugin.java:65)
        at      at java.util.TimerThread.mainLoop(Timer.java:555)
        at      at java.util.TimerThread.run(Timer.java:505)

Eclipse安装的软件列表:

  Context and Dependency Injection Tools    1.2.0.v20120504-0314-H63-Beta3  org.jboss.tools.cdi.feature.feature.group   JBoss by Red Hat
  Eclipse EGit  1.3.0.201202151440-r    org.eclipse.egit.feature.group  Eclipse EGit
  Eclipse IDE for Java EE Developers    1.4.2.20120213-0813 epp.package.jee null
  Eclipse JGit  1.3.0.201202151440-r    org.eclipse.jgit.feature.group  Eclipse JGit
  Forge Tools   1.0.0.v20120504-2048-H71-Beta3  org.jboss.tools.forge.feature.feature.group JBoss by Red Hat
  Hibernate Tools   3.4.0.v20120504-2121-H72-Beta3  org.hibernate.eclipse.feature.feature.group JBoss by Red Hat
  JBoss Archives Tools  3.2.1.v20120504-0235-H64-Beta3  org.jboss.ide.eclipse.archives.feature.feature.group    JBoss by Red Hat
  JBoss Central Community   1.0.0.v20120514-1749-H82-Beta3  org.jboss.tools.community.central.feature.feature.group JBoss by Red Hat
  JBoss JAX-RS Tools    1.2.2.v20120514-1752-H106-Beta3 org.jboss.tools.ws.jaxrs.feature.feature.group  JBoss by Red Hat
  JBoss Maven CDI Configurator  1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.cdi.feature.feature.group JBoss by Red Hat
  JBoss Maven Hibernate Configurator    1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.hibernate.feature.feature.group   JBoss by Red Hat
  JBoss Maven Integration   1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.feature.feature.group JBoss by Red Hat
  JBoss Maven JAX-RS Configurator   1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.jaxrs.feature.feature.group   JBoss by Red Hat
  JBoss Maven JPA Configurator  1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.jpa.feature.feature.group JBoss by Red Hat
  JBoss Maven JSF Configurator  1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.jsf.feature.feature.group JBoss by Red Hat
  JBoss Maven Project Examples  1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.project.examples.feature.feature.group    JBoss by Red Hat
  JBoss Maven Seam Integration  1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.seam.feature.feature.group    JBoss by Red Hat
  JBoss OpenShift Tools 2.3.0.v20120510-2034-H93-Beta3  org.jboss.tools.openshift.express.feature.feature.group JBoss by Red Hat
  JBoss Packaging Maven Configurators   1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.jbosspackaging.feature.feature.group  JBoss by Red Hat
  JBoss Runtime AS Detector 1.3.0.v20120504-1621-H89-Beta3  org.jboss.tools.runtime.as.detector.feature.feature.group   JBoss by Red Hat
  JBoss Runtime Detection Core  1.3.0.v20120504-1621-H89-Beta3  org.jboss.tools.runtime.core.feature.feature.group  JBoss by Red Hat
  JBoss Tools Community Project Examples    1.2.1.v20120504-1659-H91-Beta3  org.jboss.tools.community.project.examples.feature.feature.group    JBoss by Red Hat
  JBoss Tools EGit Integration (Experimental)   2.3.0.v20120510-2034-H93-Beta3  org.jboss.tools.openshift.egit.integration.feature.feature.group    JBoss by Red Hat
  JBoss Tools Java Standard Tools   3.3.0.v20120504-2056-H66-Beta3  org.jboss.tools.jst.feature.feature.group   null
  JBoss Tools JDT Extensions    3.3.0.v20120510-2001-H58-Beta3  org.jboss.tools.common.jdt.feature.feature.group    JBoss by Red Hat
  JBoss Tools JSF   3.3.0.v20120504-0520-H88-Beta3  org.jboss.tools.jsf.feature.feature.group   JBoss by Red Hat
  JBoss Tools RichFaces 3.3.0.v20120504-0520-H88-Beta3  org.jboss.tools.richfaces.feature.feature.group JBoss by Red Hat
  JBoss Tools Source Lookup 1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.sourcelookup.feature.feature.group    JBoss by Red Hat
  JBoss Tools Usage Reporting   1.1.0.v20120504-2022-H52-Beta3  org.jboss.tools.usage.feature.feature.group JBoss by Red Hat
  JBoss Tools Visual Page Editor    3.3.0.v20120504-2124-H75-Beta3  org.jboss.tools.vpe.feature.feature.group   null
  JBoss WebServices Tools   1.2.2.v20120514-1752-H106-Beta3 org.jboss.tools.ws.feature.feature.group    JBoss by Red Hat
  JBossAS Tools 2.3.0.v20120504-2054-H105-Beta3 org.jboss.ide.eclipse.as.feature.feature.group  JBoss by Red Hat
  JMX Console   1.2.0.v20120504-0232-H50-Beta3  org.jboss.tools.jmx.feature.feature.group   JBoss by Red Hat
  m2e - Maven Integration for Eclipse   1.0.200.20111228-1245   org.eclipse.m2e.feature.feature.group   Eclipse.org - m2e
  m2e - slf4j over logback logging (Optional)   1.0.200.20111228-1245   org.eclipse.m2e.logback.feature.feature.group   Eclipse.org - m2e
  Maven Integration for WTP 0.15.2.20120306-2040    org.maven.ide.eclipse.wtp.feature.feature.group JBoss by Red Hat
  Maven Profiles Management 1.3.0.v20120514-1625-H96-Beta3  org.jboss.tools.maven.profiles.feature.feature.group    JBoss by Red Hat
  Project Examples  1.2.1.v20120504-1659-H91-Beta3  org.jboss.tools.project.examples.feature.feature.group  JBoss by Red Hat
  Seam 3 Tools  1.2.0.v20120504-0314-H63-Beta3  org.jboss.tools.cdi.seam.feature.feature.group  JBoss by Red Hat

2 个答案:

答案 0 :(得分:2)

答案 1 :(得分:1)

我通过下载和安装"Eclipse IDE for Java Developers"(即:不是 EE包)解决了这个问题。与Eclipse的EE版本不同,基本的Java版本内置了m2e,它开箱即用。首选项条目存在,导入项目存在于菜单中等。

然后我从“帮助 - >安装新软件......”中安装了“Eclipse Java EE Developer工具”。我不知道它是否是一个完整的EE包,但EE视角和我需要的工具都在那里。您可以将普通Java版本的Eclipse EE package list与上面的列表进行比较,显示EE包具有以下附加功能包:

  • org.eclipse.datatools(数据工具)
  • org.eclipse.jpt(Java持久性工具)
  • org.eclipse.jsf(JavaServer faces)
  • org.eclipse.jst(?似乎是Web Tools Platform的部件和核心部件?)
  • org.eclipse.pde(插件开发环境)
  • org.eclipse.rse(远程系统资源管理器)
  • org.eclipse.tm(目标管理终端)
  • org.eclipse.wst(看起来是XSL支持)