问题
I've installed Eclipse Indigo SR2 EE:
Eclipse Java EE IDE for Web Developers.
Version: Indigo Service Release 2
Build id: 20120216-1857
and even after installing m2e from Marketplace I don't have any Maven menu items in File->Import, File->New->Project..., or Window->Preferences.
I'm really confused. I'm on a Fedora 17 x64 machine - and my other Fedora 17 x64 machine at work works fine with the same version of Eclipse!
m2e is clearly shown in "Installed Software":
m2e - Maven Integration for Eclipse 1.0.200.20111228-1245 org.eclipse.m2e.feature.feature.group Eclipse.org - m2e
... and appears in a configuration report. Yet it is completely invisible in the UI, and it's driving me insane.
UPDATE: There's something in the error log that might be significant - at least, it's m2e related. See -consolelog
here or abbreviated paste near end of post.
I'm fairly new to Eclipse so I'm probably doing something stupid - but whatever it is, Eclipse could make it more obvious what's wrong.
This isn't the same as "Eclipse Indigo for JAVA EE + Maven plugin = the Maven menu does not appear in import and preference"; their m2e wasn't properly installed, this shows up as installed and Eclipse won't reinstall it because it's already installed and thus greyed out in "Install new software...".
No errors are emitted on stdout/stderr when Eclipse is launched from the command line.
I'm using:
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)
which works fine on the workstation at work. ls -d plugins/*m2e*
shows:
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
The -consolelog
error that may be significant:
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)
Installed software list from 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
回答1:
I managed to install it by following the steps described at:
http://www.eclipse.org/m2e/download/
http://help.eclipse.org/juno/index.jsp?topic=//org.eclipse.platform.doc.user/tasks/tasks-127.htm
回答2:
I worked around this issue by downloading and installing "Eclipse IDE for Java Developers" (ie: not the EE package). Unlike the EE version of Eclipse, the basic Java version comes with m2e built-in, and it worked out of the box. The preferences entry was there, the import items were present in the menus, etc.
I then just installed the "Eclipse Java EE Developer tools" from "Help -> Install new software...". I don't know if it's a complete EE package, but the EE perspective and the tools I need are there. You can compare the Eclipse EE package list to the above list for the plain Java version, showing that the EE package has the following additional feature packages:
- org.eclipse.datatools (Data Tools)
- org.eclipse.jpt (Java Persistence Tools)
- org.eclipse.jsf (JavaServer faces)
- org.eclipse.jst (? Seems to be parts from Web Tools Platform and parts from core ?)
- org.eclipse.pde (Plugin development environment)
- org.eclipse.rse (Remote System Explorer)
- org.eclipse.tm (Target Management Terminal)
- org.eclipse.wst (XSL support, by the looks)
来源:https://stackoverflow.com/questions/10830284/no-maven-menu-items-in-eclipse-indigo-sr2-ee-even-after-m2e-dwm-install