Re: 2.7 can't find sources when target VM started with -jar

Nathan Fiedler <[email protected]>
Newsgroups gmane.comp.java.jswat.user
Message-ID <1027100327.1729.42.camel@chip>
The jar file is not a class name. The -jar option and the jar file
argument both need to be in the options field, and the class name needs
to be in the Class name field.

n


On Fri, 2002-07-19 at 10:20, Eric Siegerman wrote:
> I'm trying to debug an application which comes packaged as a JAR
> file -- JMeter to be specific.
> 
> In JSwat's "Start VM" window, I type:
>         Java Home:              /home/opt/j2sdk1.4.0_01/jre [i.e. the value JSwat provided]
>         JVM Executable:         java
>         Debuggee VM options:    -jar
>         Class name & arguments: /home/erics/p/jmeter/jmeter/bin/ApacheJMeter.jar
>                                                         [yup, two "jmeter/"'s]
> 
> JSwat says:
>         VM loading with following options, class name, and class arguments.
>         /home/opt/j2sdk1.4.0_01/jre/bin/java -jar  -cp "/home/erics/p/jmeter/jmeter/bin/ApacheJMeter.jar" 
>         /home/erics/p/jmeter/jmeter/bin/ApacheJMeter.jar
>         VM loaded
>         Source for class not find. Check sourcepath. (Class: /home/erics/p/jmeter/jmeter/bin/ApacheJMeter.jar )
> 
> JSwat *is* able to launch the VM, and when I hit "resume", the
> target program does indeed come up, but JSwat's source pane stays
> empty.
> 
> Note that the sources themselves are *not* jarred; they're in a
> directory tree.
> 
> The sourcepath appears correct; if I reset the classpath (since
> JSwat set it to just the JAR file) and start the VM with the
> class name instead of the "-jar jarfile", everything works.
> 
> Am I doing something wrong, or is this a bug?  It *looks* like a
> bug (that "Class: /home/erics/p/jmeter/jmeter/bin/ApacheJMeter.jar"
> seems mighty suspicious), but I'm reluctant to file a report on
> it without running it by people first...
> 
> Thanks.
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.