`./standalone.sh --debug``
You'll see something like the following output:
JAVA_OPTS: -server -verbose:gc -Xloggc:"/usr/local/devtools/rh-sso-7.2/standalone/log/gc.log" -XX:+PrintGCDetails -XX:+PrintGCDateStamps -XX:+UseGCLogFileRotation -XX:NumberOfGCLogFiles=5 -XX:GCLogFileSize=3M -XX:-TraceClassUnloading -Xms1303m -Xmx1303m -XX:MetaspaceSize=96M -XX:MaxMetaspaceSize=256m -Djava.net.preferIPv4Stack=true -Djboss.modules.system.pkgs=org.jboss.byteman -Djava.awt.headless=true -agentlib:jdwp=transport=dt_socket,address=8787,server=y,suspend=n
It will open the Java Debug Wire Protocol (jdwp) at port 8787/TCP.
For this demonstration I'll be using the Red Hat Single Sign-On 7.3.0 as application server and the keycloak-services project from the source-code provided by Red Hat.
Open the Run > Edit Configurations.. menu
Set your application server parameters or add a new one if you don't have it installed yet.
Go to the Startup/Connection tab and select Debug option. Set the Port to 8787 that is the same that was provided by application server startup (jdwp).
That's all! now, you just need to open the application in your browser or dispatch a REST api call for example to trigger your breakpoints.