[JBoss JIRA] (JBIDE-18008) Nested jars prevent SonarQube/FindBugs from running
by Max Rydahl Andersen (JIRA)
[ https://issues.jboss.org/browse/JBIDE-18008?page=com.atlassian.jira.plugi... ]
Max Rydahl Andersen commented on JBIDE-18008:
---------------------------------------------
mickael, nested jars are *very* common. It cannot be the nested jars that is the problem here is it?
> Nested jars prevent SonarQube/FindBugs from running
> ---------------------------------------------------
>
> Key: JBIDE-18008
> URL: https://issues.jboss.org/browse/JBIDE-18008
> Project: Tools (JBoss Tools)
> Issue Type: Sub-task
> Components: archives
> Reporter: Mickael Istria
> Assignee: Mickael Istria
> Fix For: 4.2.0.CR1
>
>
> Bundle org.jboss.ide.eclipse.archives.core makes SonarQube analysis fail because it's classes get included in some nested jar (and get to different location that target/classes).
> Cf https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/DevStudio/view/DevS...
> {code}
> [ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.4:sonar (default-cli) on project server.all: Can not execute SonarQube analysis: Can not execute Findbugs: Findbugs needs sources to be compiled. Please build project before executing sonar and check the location of compiled classes. -> [Help 1]
> {code}
> This is an exploded bundles with nested jars, we should investigate whether it's possible to turn it into a more standard jar, which would still be usable in its Ant version. Cf ./archives/tests/org.jboss.ide.eclipse.archives.test/inputs/projects/SimpleAntTest
> Also, the jvmmonitor bundles use nested jars. We should avoid that too.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-17938) No local processes in JMX Navigator when Eclipse is run with java 7
by Rob Stryker (JIRA)
[ https://issues.jboss.org/browse/JBIDE-17938?page=com.atlassian.jira.plugi... ]
Rob Stryker commented on JBIDE-17938:
-------------------------------------
If JVM Monitor (in the IDE) cannot load the proper tools.jar classes it needs, it will add a tools.jar to the IDE'S RUNNING CLASSPATH. This is on the IDE, not on any remote process.
JVM Monitor can't connect to a remote process without using sun.jvmstat.monitor.* classes, and if the IDE can't find those classes, it needs to add a tools.jar to the IDE's running classpath. Otherwise it can't even locate or find existing processes at all.
> No local processes in JMX Navigator when Eclipse is run with java 7
> -------------------------------------------------------------------
>
> Key: JBIDE-17938
> URL: https://issues.jboss.org/browse/JBIDE-17938
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: server
> Affects Versions: 4.2.0.Beta3
> Environment: JBDS 8.0.0.Beta3b B193
> Reporter: Martin Malina
> Assignee: Rob Stryker
> Fix For: 4.2.0.CR1
>
>
> When I install and run JBDS with java 7, there are no local processes shown in the JMX navigator.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-17938) No local processes in JMX Navigator when Eclipse is run with java 7
by Max Rydahl Andersen (JIRA)
[ https://issues.jboss.org/browse/JBIDE-17938?page=com.atlassian.jira.plugi... ]
Max Rydahl Andersen commented on JBIDE-17938:
---------------------------------------------
eh - i'm running with Java 7 and it seem to just work.
There must be more to this than *just* running with Java 7 ?
..btw. the classpath you are talking about where is that ? on the remotely running jmx process or the classloader in the IDE ?
> No local processes in JMX Navigator when Eclipse is run with java 7
> -------------------------------------------------------------------
>
> Key: JBIDE-17938
> URL: https://issues.jboss.org/browse/JBIDE-17938
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: server
> Affects Versions: 4.2.0.Beta3
> Environment: JBDS 8.0.0.Beta3b B193
> Reporter: Martin Malina
> Assignee: Rob Stryker
> Fix For: 4.2.0.CR1
>
>
> When I install and run JBDS with java 7, there are no local processes shown in the JMX navigator.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-17938) No local processes in JMX Navigator when Eclipse is run with java 7
by Rob Stryker (JIRA)
[ https://issues.jboss.org/browse/JBIDE-17938?page=com.atlassian.jira.plugi... ]
Rob Stryker commented on JBIDE-17938:
-------------------------------------
Ok... so... I found lots of interesting stuff here :D
I found that when running with java7, the tools.jar is not found. I'm not sure why. Perhaps tools.jar is not automatically added to the classpath. That's fine though.
If JVM Monitor cannot find the proper tools.jar, it will attempt to check your workspace jdk's folder for a proper tools.jar, and add it. You can customize this folder via Window -> Preferences -> JVM Monitor / Tools
The only way I was able to replicate this is as follows:
1) Have a new workspace launched with java8
2) Close that workspace
3) Run with java7 against that workspace
4) Window -> Preferences -> JRE somehow has a java8 listed
5) Window -> Preferences -> JVM Monitor / Tools also points to the java8 home directory
6) Window -> show view -> JMX
(internal below)
7) JVM Monitor attempts to load a class from tools.jar, does not find it
8) JVM Monitor adds the tools.jar from the java8 directory to the CURRENTLY RUNNING classpath
9) JVM Monitor then attempts to find a class located in tools.jar
10) This fails, because the tools.jar has too high of a .class format version (compiled for java8)
(/end internal)
11) No local processes visible
12) You go to Window -> Preferences -> JVM Monitor / Tools and point to a proper java7 folder
(internal)
13) JVM Monitor sees property has changed, attempts to add the new tools.jar to classpath
14) JVM Monitor adds the tools.jar from the java7 directory to the CURRENTLY RUNNING classpath
15) JVM Monitor then attempts to find a class located in tools.jar
16) This fails, because there are now 2 tools.jar on the currently-running classpath, and the first one that was added was java8
(/internal)
17) User can restart workspace (with the java7 java home saved in the pref page), and upon restart, should be able to see local processes
So basically, 2 problems:
1) JVM Monitor will add a new tools.jar to the classpath no matter how many times you change it. This is retarded
2) JVM Monitor will add tools.jar to the classpath even if it is a higher .class version than the currently running jvm. This is a big error
Now... ... um... to figure out how to fix it.
> No local processes in JMX Navigator when Eclipse is run with java 7
> -------------------------------------------------------------------
>
> Key: JBIDE-17938
> URL: https://issues.jboss.org/browse/JBIDE-17938
> Project: Tools (JBoss Tools)
> Issue Type: Bug
> Components: server
> Affects Versions: 4.2.0.Beta3
> Environment: JBDS 8.0.0.Beta3b B193
> Reporter: Martin Malina
> Assignee: Rob Stryker
> Fix For: 4.2.0.CR1
>
>
> When I install and run JBDS with java 7, there are no local processes shown in the JMX navigator.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-18008) Nested jars prevent SonarQube/FindBugs from running
by Mickael Istria (JIRA)
[ https://issues.jboss.org/browse/JBIDE-18008?page=com.atlassian.jira.plugi... ]
Mickael Istria commented on JBIDE-18008:
----------------------------------------
As I'm not at all an "archive" user, can you please give instruction about how to generate this .packages file?
> Nested jars prevent SonarQube/FindBugs from running
> ---------------------------------------------------
>
> Key: JBIDE-18008
> URL: https://issues.jboss.org/browse/JBIDE-18008
> Project: Tools (JBoss Tools)
> Issue Type: Sub-task
> Components: archives
> Reporter: Mickael Istria
> Fix For: 4.2.0.CR1
>
>
> Bundle org.jboss.ide.eclipse.archives.core makes SonarQube analysis fail because it's classes get included in some nested jar (and get to different location that target/classes).
> Cf https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/DevStudio/view/DevS...
> {code}
> [ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.4:sonar (default-cli) on project server.all: Can not execute SonarQube analysis: Can not execute Findbugs: Findbugs needs sources to be compiled. Please build project before executing sonar and check the location of compiled classes. -> [Help 1]
> {code}
> This is an exploded bundles with nested jars, we should investigate whether it's possible to turn it into a more standard jar, which would still be usable in its Ant version. Cf ./archives/tests/org.jboss.ide.eclipse.archives.test/inputs/projects/SimpleAntTest
> Also, the jvmmonitor bundles use nested jars. We should avoid that too.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-18008) Nested jars prevent SonarQube/FindBugs from running
by Mickael Istria (JIRA)
[ https://issues.jboss.org/browse/JBIDE-18008?page=com.atlassian.jira.plugi... ]
Mickael Istria reassigned JBIDE-18008:
--------------------------------------
Assignee: Mickael Istria
> Nested jars prevent SonarQube/FindBugs from running
> ---------------------------------------------------
>
> Key: JBIDE-18008
> URL: https://issues.jboss.org/browse/JBIDE-18008
> Project: Tools (JBoss Tools)
> Issue Type: Sub-task
> Components: archives
> Reporter: Mickael Istria
> Assignee: Mickael Istria
> Fix For: 4.2.0.CR1
>
>
> Bundle org.jboss.ide.eclipse.archives.core makes SonarQube analysis fail because it's classes get included in some nested jar (and get to different location that target/classes).
> Cf https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/DevStudio/view/DevS...
> {code}
> [ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.4:sonar (default-cli) on project server.all: Can not execute SonarQube analysis: Can not execute Findbugs: Findbugs needs sources to be compiled. Please build project before executing sonar and check the location of compiled classes. -> [Help 1]
> {code}
> This is an exploded bundles with nested jars, we should investigate whether it's possible to turn it into a more standard jar, which would still be usable in its Ant version. Cf ./archives/tests/org.jboss.ide.eclipse.archives.test/inputs/projects/SimpleAntTest
> Also, the jvmmonitor bundles use nested jars. We should avoid that too.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months
[JBoss JIRA] (JBIDE-18008) Nested jars prevent SonarQube/FindBugs from running
by Rob Stryker (JIRA)
[ https://issues.jboss.org/browse/JBIDE-18008?page=com.atlassian.jira.plugi... ]
Rob Stryker commented on JBIDE-18008:
-------------------------------------
Archives tools will, via UI, allow a user to customize how a set of projects can be built, zipped, etc. This configuration is stored in a .packages file, which is an xml file of our own custom structure.
Users at one time requested the ability to run this .packages file from ant, without having to pull in huge portions of eclipse onto the ant classpath. This required careful separation of the code so that the contents of archivescore.jar would require only very very few eclipse jars on its classpath, while the remainder of the code lived in archivescore-eclipse.jar.
The code in archivescore.jar (currently) needs to be accessible via an ant script. This means it must be a jar that lives inside an exploded plugin. Users would make an ant script, add archivescore.jar and a handful of eclipse jars to the classpath, set some properties, and be able to build a .packages file into its output archive. The ant task itself lives in archivescore.jar
> Nested jars prevent SonarQube/FindBugs from running
> ---------------------------------------------------
>
> Key: JBIDE-18008
> URL: https://issues.jboss.org/browse/JBIDE-18008
> Project: Tools (JBoss Tools)
> Issue Type: Sub-task
> Components: archives
> Reporter: Mickael Istria
> Fix For: 4.2.0.CR1
>
>
> Bundle org.jboss.ide.eclipse.archives.core makes SonarQube analysis fail because it's classes get included in some nested jar (and get to different location that target/classes).
> Cf https://jenkins.mw.lab.eng.bos.redhat.com/hudson/view/DevStudio/view/DevS...
> {code}
> [ERROR] Failed to execute goal org.codehaus.mojo:sonar-maven-plugin:2.4:sonar (default-cli) on project server.all: Can not execute SonarQube analysis: Can not execute Findbugs: Findbugs needs sources to be compiled. Please build project before executing sonar and check the location of compiled classes. -> [Help 1]
> {code}
> This is an exploded bundles with nested jars, we should investigate whether it's possible to turn it into a more standard jar, which would still be usable in its Ant version. Cf ./archives/tests/org.jboss.ide.eclipse.archives.test/inputs/projects/SimpleAntTest
> Also, the jvmmonitor bundles use nested jars. We should avoid that too.
--
This message was sent by Atlassian JIRA
(v6.2.6#6264)
11 years, 8 months