Re: GWT development locked out

2014-04-08 Thread joerg.hohwil...@googlemail.com
I went through all my dependencies for a thousand times and checked with 
mvn dependency:tree and m2e Dependency Hierarchie.
Also in Eclipse when I open the Type org.slf4j.Logger[Factory] there is 
only the one from 1.7.6. However when I debug some other version from an 
unlocatable source is loaded magically via some GWT classloader shading 
that I can not track down. I see the sourcecode of 1.7.6. LoggerFactory but 
this does not fit to the code actually running and my debugger ist stepping 
inside javadoc statements.
Output of mvn dependency:resolve does not reveal any enlightment:

[INFO] 

[INFO] Building app-war 1.0.0-SNAPSHOT
[INFO] 

[INFO] 
[INFO] --- maven-dependency-plugin:2.8:resolve (default-cli) @ mmm-app-war 
---
[INFO] 
[INFO] The following files have been resolved:
[INFO]net.sf.m-m-m:mmm-client-ui-core-api:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-service-base:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-app-core-client:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-client-ui-gwt-widgets:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-util-backport-java.util.function:jar:1.0.1:compile
[INFO]com.google.gwt:gwt-dev:jar:2.6.0:provided
[INFO]
net.sf.m-m-m:mmm-client-ui-core-api:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]org.hamcrest:hamcrest-core:jar:1.1:test
[INFO]com.google.gwt:gwt-codeserver:jar:2.6.0:provided
[INFO]
net.sf.m-m-m:mmm-service-impl-gwt:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]com.google.inject:guice:jar:3.0:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-dialog-api:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-util-core:jar:4.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-data-api:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-client-impl-gwt:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]com.google.gwt:gwt-user:jar:2.6.0:compile
[INFO]net.sf.m-m-m:mmm-util-backport-java.time-tzdb:jar:1.0.0:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-widget-impl-web-gwt:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-theme-standard:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]org.hibernate:hibernate-validator:jar:4.2.0.Final:compile
[INFO]org.slf4j:slf4j-api:jar:1.7.6:compile
[INFO]junit:junit:jar:4.10:test
[INFO]net.sf.m-m-m:mmm-security-api:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-util-gwt:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-client-impl-gwt:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-util-backport-java.time:jar:sources:1.0.0:compile
[INFO]net.sf.m-m-m:mmm-app-core-client:jar:1.0.0-SNAPSHOT:compile
[INFO]commons-logging:commons-logging:jar:1.1.3:compile
[INFO]net.sf.m-m-m:mmm-app-main-server:jar:1.0.0-SNAPSHOT:compile
[INFO]org.springframework:spring-beans:jar:4.0.2.RELEASE:compile
[INFO]net.sf.m-m-m:mmm-transaction-api:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-app-main-shared:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-client-ui-dialog-api:jar:1.0.0-SNAPSHOT:compile
[INFO]com.allen-sauer.gwt.log:gwt-log:jar:3.1.7:compile
[INFO]net.sf.m-m-m:mmm-persistence-api:jar:1.0.0-SNAPSHOT:compile
[INFO]org.slf4j:slf4j-api:jar:sources:1.7.6:compile
[INFO]net.sf.m-m-m:mmm-service-api:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]aopalliance:aopalliance:jar:1.0:compile
[INFO]net.sf.m-m-m:mmm-client-api:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-l10n-fr:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-app-core-shared:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]org.springframework:spring-context:jar:4.0.2.RELEASE:compile
[INFO]com.google.gwt.inject:gin:jar:2.0.0:compile
[INFO]net.sf.m-m-m:mmm-client-api:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]org.springframework:spring-expression:jar:4.0.2.RELEASE:compile
[INFO]org.springframework:spring-web:jar:4.0.2.RELEASE:compile
[INFO]net.sf.m-m-m:mmm-service-base:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]ch.qos.logback:logback-classic:jar:1.1.1:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-widget-impl-web-gwt:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]c3p0:c3p0:jar:0.9.1.2:test
[INFO]net.sf.m-m-m:mmm-client-ui-widget-base:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-dialog-impl-gwt:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]javax.annotation:jsr250-api:jar:1.0:compile
[INFO]net.sf.m-m-m:mmm-app-core-shared:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-client-ui-widget-api:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-widget-api:jar:sources:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-l10n-de:jar:1.0.0-SNAPSHOT:compile
[INFO]
net.sf.m-m-m:mmm-client-ui-theme-standard:jar:1.0.0-SNAPSHOT:compile
[INFO]net.sf.m-m-m:mmm-test:jar:0-SNAPSHOT:test
[INFO]

Re: GWT development locked out

2014-04-08 Thread Thomas Broyer


On Monday, April 7, 2014 10:14:31 PM UTC+2, joerg.h...@googlemail.com wrote:

 Hi there,

 with my GWT application I ran into the problem that I can not run/debug 
 anymore.

 1. With DevMode I get this:
 SLF4J: The requested version 1.6 by your slf4j binding is not compatible 
 with [1.5.5, 1.5.6]
 SLF4J: See http://www.slf4j.org/codes.html#version_mismatch for further 
 details.
 ...
 Caused by: java.lang.NoSuchMethodError: 
 org.slf4j.helpers.MessageFormatter.arrayFormat(Ljava/lang/String;[Ljava/lang/Object;)Lorg/slf4j/helpers/FormattingTuple;
 at 
 ch.qos.logback.classic.spi.LoggingEvent.getFormattedMessage(LoggingEvent.java:298)

 The exception is caused by a log statement during the init process of my 
 app. When I then click the launch URL I just get
 HTTP ERROR: 503

 I tried both logback as well as log4j12 binding. I scanned my entire 
 classpath and tried all combinations of slf4j-api and binding versions. But 
 I always get this error. To me it seems that either GWT or Jetty is shipped 
 with an internal but obsolete slf4j version but I can not find it and track 
 it down. I added a classloader breakpoint and can not see from where it 
 loads the old version. However, he does not use the version I have put on 
 my classpath.

 I had a workaround with jetty-web.xml but this stopped to work so I am 
 totally stuck here.

Should be fixed in 2.6.1, to be released soon (last call for patches ends 
this Friday)

 

 2. With SuperDevMode I get this:

 workDir: 
 C:\Users\hohwille\AppData\Local\Temp\gwt-codeserver-2916897945350199638.tmp
 22:09:14.326 [main] DEBUG org.eclipse.jetty.util.log - Logging to 
 Logger[org.eclipse.jetty.util.log] via org.eclipse.jetty.util.log.Slf4jLog
 binding: user.agent=safari
 binding: compiler.useSourceMaps=true
 binding: locale=en
 Compiling module net.sf.mmm.app.Mmm
Validating units:
   Ignored 21 units with compilation errors in first pass.
 Compile with -strict or with -logLevel set to TRACE or DEBUG to see all 
 errors.
Finding entry point classes
   [ERROR] Unable to find type 'net.sf.mmm.app.client.Mmm'
  [ERROR] Hint: Check that the type name 
 'net.sf.mmm.app.client.Mmm' is really what you meant
  [ERROR] Hint: Check that your classpath includes all required 
 source roots
 [ERROR] Compiler returned false
 com.google.gwt.core.ext.UnableToCompleteException: (see previous log 
 entries)
 at 
 com.google.gwt.dev.codeserver.Recompiler.compile(Recompiler.java:128)
 at 
 com.google.gwt.dev.codeserver.ModuleState.init(ModuleState.java:58)
 at 
 com.google.gwt.dev.codeserver.CodeServer.makeModules(CodeServer.java:120)
 at com.google.gwt.dev.codeserver.CodeServer.start(CodeServer.java:95)
 at com.google.gwt.dev.codeserver.CodeServer.main(CodeServer.java:71)
 at com.google.gwt.dev.codeserver.CodeServer.main(CodeServer.java:49)

 My launch config is as following:

 ?xml version=1.0 encoding=UTF-8 standalone=no?
 launchConfiguration type=org.eclipse.jdt.launching.localJavaApplication
 listAttribute key=org.eclipse.debug.core.MAPPED_RESOURCE_PATHS
 listEntry value=/mmm-app-war/
 /listAttribute
 listAttribute key=org.eclipse.debug.core.MAPPED_RESOURCE_TYPES
 listEntry value=4/
 /listAttribute
 booleanAttribute 
 key=org.eclipse.jdt.launching.ATTR_USE_START_ON_FIRST_THREAD 
 value=true/
 stringAttribute key=org.eclipse.jdt.launching.CLASSPATH_PROVIDER 
 value=org.eclipse.m2e.launchconfig.classpathProvider/
 stringAttribute key=org.eclipse.jdt.launching.MAIN_TYPE 
 value=com.google.gwt.dev.codeserver.CodeServer/
 stringAttribute key=org.eclipse.jdt.launching.PROGRAM_ARGUMENTS 
 value=-port  net.sf.mmm.app.Mmm/
 stringAttribute key=org.eclipse.jdt.launching.PROJECT_ATTR 
 value=mmm-app-war/
 stringAttribute key=org.eclipse.jdt.launching.SOURCE_PATH_PROVIDER 
 value=org.eclipse.m2e.launchconfig.sourcepathProvider/
 stringAttribute key=org.eclipse.jdt.launching.VM_ARGUMENTS 
 value=-XX:MaxPermSize=256m -Xmx512m/
 /launchConfiguration


As Jens said, you need to feed CodeServer with the source files too. Either 
add an -src argument or just add your source folders (src/main/java, no 
need to add src/main/resources as Eclipse automatically copies them to the 
target/classes –or target/finalName/WEB-INF/classes– which it puts in the 
classpath) to the classpath.

-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.


Re: GWT development locked out

2014-04-07 Thread Jens
For your first problem in DevMode:

GWT 2.6 uses Jetty 8 which is compiled against slf4j-api-1.6.x. Also GWT's 
svn repository, that stores all 3rd party libraries, only 
contains slf4j-api-1.6.1 and slf4j-log4j12-1.6.1. 

So I would assume something in your maven project provides a 1.5.x binding. 
Does mvn dependency:resolve show anything?


For your SDM problem:

You must make sure that your project's class AND source files are available 
to SDM. From command line you would launch SDM using

java -classpath project class files:project libs:gwt sdk + 
codeserver.jar com.google.gwt.dev.codeserver.CodeServer -src project 
source module name

If you forget the -src parameter I think you get the error message you are 
seeing. So I would assume its a maven / pom issue.


Speaking of Maven:

it seems like your pom still references gwt-maven-plugin version 2.5.1 
although you are using GWT 2.6. Maybe you should change that.

https://github.com/m-m-m/mmm/blob/master/pom.xml#L335


-- J.


-- 
You received this message because you are subscribed to the Google Groups 
Google Web Toolkit group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to google-web-toolkit+unsubscr...@googlegroups.com.
To post to this group, send email to google-web-toolkit@googlegroups.com.
Visit this group at http://groups.google.com/group/google-web-toolkit.
For more options, visit https://groups.google.com/d/optout.