facebook

[Closed]debug in Tomcat

  1. MyEclipse IDE
  2.  > 
  3. General Development
Viewing 10 posts - 1 through 10 (of 10 total)
  • Author
    Posts
  • #245310 Reply

    lukmanph
    Member

    Hi there

    my config:
    Eclipse 3.1.1
    Myeclipse 4.0.3 GA
    Tomcat 5.0.28
    jdk 1.4.2

    when I debug with Tomcat, it does not refresh the code, and i have the ‘reloadable’ set to true for my web application.
    Example, if i change a line of code during a debug session, it won’t refresh it.
    So i start up Tomcat again but it keeps debugging a old line of code (which has been already deleted but that had a breakpoint, and removed all previously set breakpoints).
    thanks in advance

    #245344 Reply

    Riyad Kalla
    Member

    Are you using an exploded deployment?

    #245403 Reply

    lukmanph
    Member

    yes, I’m

    #245452 Reply

    Riyad Kalla
    Member

    Try this:
    1) Deploy your project
    2) Wait a few minutes (yes minutes)
    3) Fire up tomcat
    4) Open up the deployment dialog, select your deployment and click Browse
    5) Now drill down to the classes subdirectory of a class you want to change. Display the “details” view of your file listing to see the time stamp
    6) Go back to MyEclipse, open that Java file up for that class, and add a space at the end of it and save it.
    7) Did you see the timestamp in the file explorer update?

    #245544 Reply

    lukmanph
    Member

    hi Riyad

    i just did that, and no, the timestamp of the class does not change in the File Explorer ….

    #245554 Reply

    Riyad Kalla
    Member

    Ok that’s not good. Please give me your Eclipse Build ID (Help > About menu) and your MyEclipse Build ID (MyEclipse > About menu).

    Also check your log file (<workspace dir>\.metadata\.log) for exceptions near the bottom pertaining to deployment.

    Also is this a Web, EJB or EAP project?

    #245570 Reply

    lukmanph
    Member

    hi Riyad

    i reinstalled latest version of MyEclipse with a clean Eclipse installation and everything seems to be working now.
    however, got a question:
    1- if i deploy a webapp on Tomcat, and declare it as the default application in server.xml, the hot swap works without restarting the context of the application. however,if deployed as not the default application, it restarts up the context… is it the expected behaviour?

    cheers
    Patria

    #245571 Reply

    Riyad Kalla
    Member

    1- if i deploy a webapp on Tomcat, and declare it as the default application in server.xml, the hot swap works without restarting the context of the application. however,if deployed as not the default application, it restarts up the context… is it the expected behaviour?

    Patria,
    MyEclipse doesn’t handle this behavior. This is determined by the “reloadable=true” property set for that context. Double check your config files, you can probably set that to false and tomcat will stop reloading the context.

    #245598 Reply

    lukmanph
    Member

    ok,got it….
    thanks for your reply

    #256394 Reply

    ranimathur
    Member

    Hi Riyad,

    I got the same issue, I m using my eclipse version 4.1.1 and Resin as application server (resin-pro-3.0.14), jdk 1.4.2 and eclipse 3.1.0.

    Sometimes when i m debugging and I find the problem –> change the file –> save it –> it runs changes too.
    but sometimes it doesn’t ?? any specific reason ??

Viewing 10 posts - 1 through 10 (of 10 total)
Reply To: [Closed]debug in Tomcat

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