[quote="gregfqt" post=3708]1. I would not recommend importing / keeping opened the modules you don't work on because, based on our experience, eclipse + maven + osgi integration is not _that_ good [/quote]
Actually I'm confused with this one; other than tm/tm.web and tm/tm.service, what other necessary modules do I need to add from the root folder for Squash to run? Do I actually need to add the root folder?
I also don't really know if I actually need to add the root folder really; if I added the root folder first (i.e. squashtest-tm), wouldn't that actually duplicate tm/tm.web and tm/tm.service folders if you add these two afterwards? I attached a screen capture for this:
[attachment=249]dup.png[/attachment]
And, if I added the root folder first in Eclipse and later the two folders, Eclipse will warn me that the two folders are already inside the root folder; so what I did was I added the two folders first, then I added the root folder.
I tried running Squash with only tm.service and tm.web first and it gave me errors, as you'll see below. (Running using the root module together with tm.service and tm.web can be found below as well)
[quote="gregfqt" post=3708]
2. You have to disable aspectj nature because here abgain, based on our experience, it breaks groovy integration. [/quote]
I captured a screen capture for this one (it's on the prior post); would the steps be enough? I just right click on the tm.service folder and selected Remove AspectJ Capability.
[quote="gregfqt" post=3708]
The downside is that sometimes, as eclipse has no knowledge of the aspects, they won't be weaved. In that case, run mvn clean install [/quote]
How do you mean? AspectJ is not detected? How could I know if it's not detected? Should I run the command you mentioned on the root folder and then remove the AspectJ Capability like I mentioned before?
[quote="gregfqt" post=3708]
3. When workspace bundles are marked "out of sync" in the run configuration, you may try to refresh the projects. When they still are marked out of sync, it usually means there is an "org.eclipse.pde.*.prefs" file in the project's ".settings" folder which is messing around. Please remove it / them as stated here.[url=
https://bitbucket.org/nx/squashtest-tm/ ... -workspace]here[/url] [/quote]
These are the .pde files:
[attachment=247]pdefile.png[/attachment]
I deleted them, restarted Eclipse, clicked on refresh but nothing happened (i.e. I still get some error symbols on each folder)
[quote="gregfqt" post=3708]
4. What are your validation errors ? They may be caused by the "out of sync" bundles and this would explain why the app won't start [/quote]
If I only use tm.service and tm.web, then I won't get any validation errors. If I used the root folder, tm.service and tm.web, I'll get this error:
[attachment=250]validationerror.png[/attachment]
[quote="gregfqt" post=3708]
5. The maven plugins unknown to m2e should be of no consequences. Their goal is to process web assets and the app sould properly work in eclipse provided you ran maven and did not modify them afterwards.[/quote]
Assuming that I only used tm.service and tm.web and run them, this happened:
[i]osgi> log4j:WARN No appenders could be found for logger (org.eclipse.jetty.util.log).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See
http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
!SESSION 2015-02-26 08:35:48.016 -----------------------------------------------
eclipse.buildId=unknown
java.version=1.7.0_60
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_US
Command-line arguments: -dev file:C:/Users/Z/workspace7/.metadata/.plugins/org.eclipse.pde.core/New_configuration/dev.properties -os win32 -ws win32 -arch x86_64 -consoleLog -os win32 -ws win32 -arch x86_64 -consoleLog -console
!ENTRY org.squashtest.csp.core.log4j 4 0 2015-02-26 08:36:00.029
!MESSAGE FrameworkEvent ERROR
!STACK 0[/i]
.
.
.
[i]Root exception:
java.io.FileNotFoundException: C:\Users\Z\workspace7\\provision\target\config\services\log4j.properties (The filename, directory name, or volume label syntax is incorrect)
at java.io.FileInputStream.open(Native Method)
at java.io.FileInputStream.(Unknown Source)
at java.io.FileReader.(Unknown Source)
at org.squashtest.csp.core.log4j.Activator.start(Activator.java:57)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl$1.run(BundleContextImpl.java:711)
at java.security.AccessController.doPrivileged(Native Method)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.startActivator(BundleContextImpl.java:702)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:683)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1131)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
[b]!ENTRY org.eclipse.osgi 4 0 2015-02-26 08:36:00.793
!MESSAGE Bundle org.squashtest.csp.core.log4j_1.12.0.M1-SNAPSHOT [100] is not active.[/b][/i]
___________________________________________________
Now, lets say I added the root folder and try running it again (if I added the root folder, some new .pde files are generated so I deleted them and restarted Eclipse as well:
[attachment=248]pdefile2.png[/attachment]
For the validation error:
[attachment=250]validationerror.png[/attachment]
Here's the bundles configurations (the rest I left it blank):
[attachment=251]bundles.png[/attachment]
And the output after running:
[i]osgi> log4j:WARN No appenders could be found for logger (org.eclipse.jetty.util.log).
log4j:WARN Please initialize the log4j system properly.
log4j:WARN See
http://logging.apache.org/log4j/1.2/faq.html#noconfig for more info.
!SESSION 2015-02-26 09:07:09.797
eclipse.buildId=unknown
java.version=1.7.0_60
java.vendor=Oracle Corporation
BootLoader constants: OS=win32, ARCH=x86_64, WS=win32, NL=en_US
Command-line arguments: -dev file:C:/Users/Z/workspace7/.metadata/.plugins/org.eclipse.pde.core/New_configuration/dev.properties -os win32 -ws win32 -arch x86_64 -consoleLog -os win32 -ws win32 -arch x86_64 -consoleLog -console
!ENTRY org.squashtest.csp.core.log4j 4 0 2015-02-26 09:07:18.130
!MESSAGE FrameworkEvent ERROR
!STACK 0
org.osgi.framework.BundleException: The activator org.squashtest.csp.core.log4j.Activator for bundle org.squashtest.csp.core.log4j is invalid
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:171)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1131)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
Caused by: java.lang.ClassNotFoundException: org.squashtest.csp.core.log4j.Activator
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(Unknown Source)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:164)
... 12 more
Root exception:
java.lang.ClassNotFoundException: org.squashtest.csp.core.log4j.Activator
at org.eclipse.osgi.internal.loader.BundleLoader.findClassInternal(BundleLoader.java:513)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:429)
at org.eclipse.osgi.internal.loader.BundleLoader.findClass(BundleLoader.java:417)
at org.eclipse.osgi.internal.baseadaptor.DefaultClassLoader.loadClass(DefaultClassLoader.java:107)
at java.lang.ClassLoader.loadClass(Unknown Source)
at org.eclipse.osgi.internal.loader.BundleLoader.loadClass(BundleLoader.java:345)
at org.eclipse.osgi.framework.internal.core.BundleHost.loadClass(BundleHost.java:229)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.loadBundleActivator(AbstractBundle.java:164)
at org.eclipse.osgi.framework.internal.core.BundleContextImpl.start(BundleContextImpl.java:679)
at org.eclipse.osgi.framework.internal.core.BundleHost.startWorker(BundleHost.java:381)
at org.eclipse.osgi.framework.internal.core.AbstractBundle.resume(AbstractBundle.java:389)
at org.eclipse.osgi.framework.internal.core.Framework.resumeBundle(Framework.java:1131)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:559)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.resumeBundles(StartLevelManager.java:544)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.incFWSL(StartLevelManager.java:457)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.doSetStartLevel(StartLevelManager.java:243)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:438)
at org.eclipse.osgi.framework.internal.core.StartLevelManager.dispatchEvent(StartLevelManager.java:1)
at org.eclipse.osgi.framework.eventmgr.EventManager.dispatchEvent(EventManager.java:230)
at org.eclipse.osgi.framework.eventmgr.EventManager$EventThread.run(EventManager.java:340)
!ENTRY org.eclipse.osgi 4 0 2015-02-26 09:07:18.141
!MESSAGE Bundle org.squashtest.csp.core.log4j_1.12.0.M1-SNAPSHOT [170] is not active.
!ENTRY org.eclipse.osgi 2 0 2015-02-26 09:07:18.312
!MESSAGE One or more bundles are not resolved because the following root constraints are not resolved:
!SUBENTRY 1 org.eclipse.osgi 2 0 2015-02-26 09:07:18.312
!MESSAGE Bundle initial@reference:file:../../../../core/core.jetty.boot.felix42.fragment/ was not resolved.
!SUBENTRY 2 org.squashtest.tm.core.jetty.boot.felix42.fragment 2 0 2015-02-26 09:07:18.313
!MESSAGE Missing imported package org.eclipse.jetty.osgi.boot.utils.internal_0.0.0.
!ENTRY org.eclipse.osgi 2 0 2015-02-26 09:07:18.315
!MESSAGE The following is a complete list of bundles which are not resolved, see the prior log entry for the root cause if it exists:
!SUBENTRY 1 org.eclipse.osgi 2 0 2015-02-26 09:07:18.315
!MESSAGE Bundle org.squashtest.tm.core.jetty.boot.felix42.fragment_1.12.0.M1-SNAPSHOT [166] was not resolved.
!SUBENTRY 2 org.squashtest.tm.core.jetty.boot.felix42.fragment 2 0 2015-02-26 09:07:18.315
!MESSAGE Missing imported package org.eclipse.jetty.osgi.boot.utils.internal_0.0.0.
[/i]
Hope you'll get back to me : /