• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Tomcat Add and Remove

 
Ranch Hand
Posts: 1402
3
Netbeans IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hi all,

I am trying to debug a method within a Class annotated with the @RestController.

I try to Add the project to the Tomcat 8 server but is says there are not projects to be added.

I am debugging th same way as with a Java File without @RestController.

Is my proceding correct?

 
Saloon Keeper
Posts: 27752
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I think you are confusing your IDE with Tomcat. Your terminology doesn't make any sense for a Tomcat application and Tomcat doesn't work with "projects", it works with web applications (which aren't "added", they're "deployed").
 
Angus Ferguson
Ranch Hand
Posts: 1402
3
Netbeans IDE Spring Java
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Yes I meant a web application (Spring Boot).

From the main  class @SpringBootApplication, it scan a component which contains a  @RequestMapping annotation, it reaches it well but I would like to debug  the content of the method reached...it just doesnt debug even when the local Tomcat is in debug mode.
 
Tim Holloway
Saloon Keeper
Posts: 27752
196
Android Eclipse IDE Tomcat Server Redhat Java Linux
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
In the case of Spring Boot, Tomcat is embedded within the Spring Boot framework. So to use a debugger, you have to start the Spring Boot application with debugging enabled.

I'm not sure what you mean by "Tomcat debugging enabled" for that reason. When Tomcat runs stand-alone, the startup script (catalina.sh/catalina.bat) adds remote debug options to the JVM execution command line that it builds. In the case of an embedded Tomcat, you'd have to start whatever JVM runs the app that has Tomcat (and the webapp) embedded within it with JVM debug options. I've never played with Spring Boot to that degree, though, and if you have an IDE plugin, it may have options of its own.
 
Consider Paul's rocket mass heater.
reply
    Bookmark Topic Watch Topic
  • New Topic