Avatar of Sathish David  Kumar N
Sathish David Kumar NFlag for India

asked on 

how to debug java code in apache http server deployment

hi my application contain angular js and spring code.

we deploy our code in apache 2.4 .x server.
is that any possibility to debug the code using eclipse??
because I am using  and clean install to generate war.
through command prompt i deploy my code. not in eclipse run on server
 can you help me to debug the code
JavaJava EEApache Web Server

Avatar of undefined
Last Comment
Sathish David Kumar N
Avatar of girionis
girionis
Flag of Greece image

Start your spring server with the debug option

-Xdebug -Xrunjdwp:server=y,transport=dt_socket,address=4000,suspend=n myapp

Open in new window


then in Eclipse from "Run" -> "Debug Configurations..." choose the "Remote Java Application" and enter the port number 4000. And you're ready to go.
Avatar of Sathish David  Kumar N

ASKER

How to create break point in the jar
how to do debug ?
Avatar of girionis
girionis
Flag of Greece image

You just create a break point in Eclipse, in the source code (click on the left of the line you want to set the break point).
its giving error
Error: Could not find or load main class suspend=n
Avatar of girionis
girionis
Flag of Greece image

Show me the command line.
ASKER CERTIFIED SOLUTION
Avatar of Sathish David  Kumar N
Sathish David Kumar N
Flag of India image

Blurred text
THIS SOLUTION IS ONLY AVAILABLE TO MEMBERS.
View this solution by signing up for a free trial.
Members can start a 7-Day free trial and enjoy unlimited access to the platform.
See Pricing Options
Start Free Trial
Avatar of Sathish David  Kumar N

ASKER

application  jar in eclipse itself *
Avatar of girionis
girionis
Flag of Greece image

So how did you do it then? The command I posted in my first post works for spring boot.
Avatar of Sathish David  Kumar N

ASKER

no i add sts plugin in eclipse
Avatar of girionis
girionis
Flag of Greece image

Ah.. ok, so you're running spring boot from within Eclipse...
Avatar of Sathish David  Kumar N

ASKER

yes
Java
Java

Java is a platform-independent, object-oriented programming language and run-time environment, designed to have as few implementation dependencies as possible such that developers can write one set of code across all platforms using libraries. Most devices will not run Java natively, and require a run-time component to be installed in order to execute a Java program.

102K
Questions
--
Followers
--
Top Experts
Get a personalized solution from industry experts
Ask the experts
Read over 600 more reviews

TRUSTED BY

IBM logoIntel logoMicrosoft logoUbisoft logoSAP logo
Qualcomm logoCitrix Systems logoWorkday logoErnst & Young logo
High performer badgeUsers love us badge
LinkedIn logoFacebook logoX logoInstagram logoTikTok logoYouTube logo