facebook

Debugger doesn’t use Java project in Maven web project

  1. MyEclipse IDE
  2.  > 
  3. Maven for MyEclipse (Maven4MyEclipse)
Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #314147 Reply

    Seldon Systems
    Participant

    Hi,

    I use MyEclipse 8.6.1 all-in-one on OS X 10.6.6. I have a web application using Maven that I deploy to Tomcat 6 using MyEclipse. Now that web project depends on three other Maven Java projects of interest. Now in WEB-INF/lib, these projects are “deployed” with version 1.3.3. In the pom.xml, the web project depends on version 1.3.4-SNAPSHOT of these projects. I have these three projects open in my workspace, so the POM shows them with the “open folder icon” instead of the “JAR glass one”.

    Here’s my problem: I changed in a class in one of the Java projects and put a breakpoint on it. Now when that breakpoint is hit, the debugger loads a .class file for that class, and based on the title description, it’s actually version 1.3.2.

    Two question:

    1) Opening version 1.3.2 seems like a bug to me, no matter what. Correct?

    2) Bug aside, can I actually debug directly against my open Java project dependency in my web app, or do I need to install this project dependency locally in my Maven repository, close it in the workspace, package my web project to force an update to WEB-INF/lib and then clean up there (MyEclipse typically doesn’t remove old JAR versions) before I can debug my web project?

    #314189 Reply

    Seldon Systems
    Participant

    As it turns out, it was the same old “Eclipse debugger loads the first version of a class in workspace” problem. I had another project with the old version 1.3.2 of this class, so that got used. As soon as I closed that project, the debugger picked the proper class from the Java project that my web project depended upon.

Viewing 2 posts - 1 through 2 (of 2 total)
Reply To: Debugger doesn’t use Java project in Maven web project

You must be logged in to post in the forum log in