Issues with Hello World example for beginners [message #1747277] |
Fri, 11 November 2016 09:56  |
Eclipse User |
|
|
|
A fix and a problem ...
I have a habit of not proceeding forward until I understand where I am ... and at the moment that involves:
Ubuntu 16.04.1
Eclipse Neon 1a
Scout 4.6.1
and (when I get to it Apache Tomcat 8.0.32)
and Oracle Java 8 u111
First, if Apache is up and running, following the example documentation directly will lead to an error because the port 8080 has already been taken.
Fix:
Fix for 8080 already taken:
helloworld.server.app.dev [webapp] dev server.launch:
change 8080 to 8081 as here:
<stringAttribute key="org.eclipse.jdt.launching.VM_ARGUMENTS" value="-Dscout.jetty.port=8081
-Djandex.rebuild=true"/>
AND in helloworld.ui.html.app.dev src/main/resources/config.properties:
change 8080 t0 8081 as here:
scout.server.url=http://localhost:8081
Then you may be faced with the next issue, which is my PROBLEM:
SLF4J: Failed to load class "org.slf4j.impl.StaticLoggerBinder".
SLF4J: Defaulting to no-operation (NOP) logger implementation
In trying to solve that with "many" ideas from the web, all of which fail in one way or another, I found what "seems" to be a bug in Eclipse, Scout or Maven, and I do not know which:
The most straight forward way to reproduce, is to go to the
helloworld.shared pop.xml and remove the dependency on ch.qos.logback.
If you then:
do a Scout "update all derived resource" (Needed ??)
then a maven update all projects,
you immediately get these compile errors:
Description Resource Path Location Type
HelloWorldFormData cannot be resolved to a type HelloWorldForm.java /helloworld.client/src/main/java/org/eclipse/scout/apps/helloworld/client/helloworld line 23 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldForm.java /helloworld.client/src/main/java/org/eclipse/scout/apps/helloworld/client/helloworld line 93 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldForm.java /helloworld.client/src/main/java/org/eclipse/scout/apps/helloworld/client/helloworld line 93 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 42 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 42 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 45 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldService.java /helloworld.server/src/main/java/org/eclipse/scout/apps/helloworld/server/helloworld line 15 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldService.java /helloworld.server/src/main/java/org/eclipse/scout/apps/helloworld/server/helloworld line 15 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldServiceTest.java /helloworld.server/src/test/java/org/eclipse/scout/apps/helloworld/server/helloworld line 28 Java Problem
HelloWorldFormData cannot be resolved to a type HelloWorldServiceTest.java /helloworld.server/src/test/java/org/eclipse/scout/apps/helloworld/server/helloworld line 28 Java Problem
HelloWorldFormData cannot be resolved to a type IHelloWorldService.java /helloworld.shared/src/main/java/org/eclipse/scout/apps/helloworld/shared/helloworld line 15 Java Problem
HelloWorldFormData cannot be resolved to a type IHelloWorldService.java /helloworld.shared/src/main/java/org/eclipse/scout/apps/helloworld/shared/helloworld line 15 Java Problem
The import org.eclipse.scout.apps.helloworld.shared.helloworld.HelloWorldFormData cannot be resolved HelloWorldForm.java /helloworld.client/src/main/java/org/eclipse/scout/apps/helloworld/client/helloworld line 15 Java Problem
The import org.eclipse.scout.apps.helloworld.shared.helloworld.HelloWorldFormData cannot be resolved HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 16 Java Problem
The import org.eclipse.scout.apps.helloworld.shared.helloworld.HelloWorldFormData cannot be resolved HelloWorldService.java /helloworld.server/src/main/java/org/eclipse/scout/apps/helloworld/server/helloworld line 4 Java Problem
The import org.eclipse.scout.apps.helloworld.shared.helloworld.HelloWorldFormData cannot be resolved HelloWorldServiceTest.java /helloworld.server/src/test/java/org/eclipse/scout/apps/helloworld/server/helloworld line 12 Java Problem
The import org.eclipse.scout.apps.helloworld.shared.helloworld.HelloWorldFormData cannot be resolved IHelloWorldService.java /helloworld.shared/src/main/java/org/eclipse/scout/apps/helloworld/shared/helloworld line 6 Java Problem
The method load(HelloWorldFormData) from the type IHelloWorldService refers to the missing type HelloWorldFormData HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 45 Java Problem
The type HelloWorldService must implement the inherited abstract method IHelloWorldService.load(HelloWorldFormData) HelloWorldService.java /helloworld.server/src/main/java/org/eclipse/scout/apps/helloworld/server/helloworld line 12 Java Problem
Type mismatch: cannot convert from HelloWorldFormData to HelloWorldFormData HelloWorldFormTest.java /helloworld.client/src/test/java/org/eclipse/scout/apps/helloworld/client/helloworld line 45 Java Problem
Fair enough (perhaps), but if you ADD those lines back - and the file is EXACTLY as it was before, repeat the refresh steps above,
YOU STILL have the compile errors.
And I have found no way to get rid of them once I have them, except delete the projects and start again.
This "seems" like a bug, but I don't know what piece of software is the issue (or if I am missing some step that needs to be done to "fresh" things.
It "seems" that the generated code for HelloWordFormData has been orphaned in some way - but it is still there.
I have repeated this from scratch to make sure of steps.
|
|
|
|
|
|
|
Powered by
FUDForum. Page generated in 0.04000 seconds