Skip to main content

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index] [List Home]
[m2e-users] Maven Console broken in Eclipse for DSL Developers

Hi,

I have/had (resolved with a dirty hack) a problem with the Maven Console in Eclipse for DSL Developers. By default, this variant of Eclipse comes without the org.eclipse.m2e.logback.feature[1], so the Maven console does not work at all. But installing it does not fix the Maven console. The root cause seems to be that when EGit and M2E are installed in one Eclipse there are 2 SLF4J Backends active and in the case of the DSL-Eclipse the log4j backand provided by EGit wins. If you redirect the output of an Eclipse start (on Windows, on Linux it will be visible from the console where you started Eclipse), you get these outputs:

For Eclipse for Java Developers:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [bundleresource://476.fwk820587705:1/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [bundleresource://476.fwk820587705:2/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [ch.qos.logback.classic.util.ContextSelectorStaticBinder]

And for Eclipse for DSL Developers:
SLF4J: Class path contains multiple SLF4J bindings.
SLF4J: Found binding in [bundleresource://461.fwk352378889:1/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: Found binding in [bundleresource://461.fwk352378889:2/org/slf4j/impl/StaticLoggerBinder.class]
SLF4J: See http://www.slf4j.org/codes.html#multiple_bindings for an explanation.
SLF4J: Actual binding is of type [org.slf4j.impl.Log4jLoggerFactory]
org.eclipse.m2e.logback.configuration: SLF4J logger factory is not an instance of LoggerContext: org.slf4j.impl.Log4jLoggerFactory

I "fixed" this by removing the line for org.slf4j.impl.log4j12 from bundles.info, but I think that's a rather inelegant solution ;)

I'm not sure whose fault this is, but it would be nice if someone could point me to the correct bugtracker to get this resolved properly.

Regards, Tobias

[1] Compare https://github.com/eclipse/epp.packages/blob/MARS/packages/org.eclipse.epp.package.java.feature/feature.xml and https://github.com/eclipse/epp.packages/blob/MARS/packages/org.eclipse.epp.package.dsl.feature/feature.xml 


Back to the top