Start JEE AEM Forms in Debug mode for Eclipse | Community
Skip to main content
New Participant
December 31, 2021
Solved

Start JEE AEM Forms in Debug mode for Eclipse

  • December 31, 2021
  • 1 reply
  • 1011 views

How do I start AEM Forms on JEE in Debug mode for Eclipse? I have found this AEM Developer Tools for Eclipse | Adobe Experience Manager and this Debug an AEM app using eclipse (adobe.com) but nothing I have found tells where to put the JVM parameter on a JEE instance.

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by Pulkit_Jain_

@gphillips58 

As per the blogs here[0][1], it depends on what you want to debug :

  • to debug the Host Controller (that means the server that manages the domain) use the domain.conf file or set the environment variable PROCESS_CONTROLLER_JAVA_OPTS

    PROCESS_CONTROLLER_JAVA_OPTS="$PROCESS_CONTROLLER_JAVA_OPTS -agentlib:jdwp=transport=dt_socket,address=8788,server=y,suspend=n"

  • to debug a server instance of your domain you have to pass jvm args in your host.xml, for example to debug server-one. I assume this must be the case, so more details provided in the blogs.

 

[0] - https://developer.jboss.org/thread/230399

[1] - https://stackoverflow.com/questions/26927082/wildfly-domain-mode-debug 

1 reply

Pulkit_Jain_
Employee
January 4, 2022

@gphillips58 

Steps to enable debug for OSGi stack of the JEE instance should be the same as mentioned here- Debug an AEM app using eclipse (adobe.com)

For enabling remote debugging on a JEE set-up (assuming based on JBoss), edit your <jboss install location>/bin/standalone.conf. Now, look for [0] and uncomment it. It should be near the bottom. Similarly you can follow similar steps for other App servers, as applicable. 

Then you can configure the eclipse AEM server settings for that port, example - 8787. I assume this should suffice, please let us know your findings.

 

Hope this helps.

 

 

[0] - # JAVA_OPTS=”$JAVA_OPTS -Xrunjdwp:transport=dt_socket,address=8787,server=y,suspend=n”

 

New Participant
January 10, 2022

Yes, it is JBoss (on windows). We are running a cluster so I looked in the domain.conf.bat and found this:

rem # Sample JPDA settings for remote socket debugging
rem set "PROCESS_CONTROLLER_JAVA_OPTS=%PROCESS_CONTROLLER_JAVA_OPTS% -agentlib:jdwp=transport=dt_socket,address=8788,server=y,suspend=n"
rem set "HOST_CONTROLLER_JAVA_OPTS=%HOST_CONTROLLER_JAVA_OPTS% -agentlib:jdwp=transport=dt_socket,address=8787,server=y,suspend=n"

 

Do we uncomment both lines or just one? If just one, which one?

 

Thanks

Pulkit_Jain_
Pulkit_Jain_Accepted solution
Employee
January 11, 2022

@gphillips58 

As per the blogs here[0][1], it depends on what you want to debug :

  • to debug the Host Controller (that means the server that manages the domain) use the domain.conf file or set the environment variable PROCESS_CONTROLLER_JAVA_OPTS

    PROCESS_CONTROLLER_JAVA_OPTS="$PROCESS_CONTROLLER_JAVA_OPTS -agentlib:jdwp=transport=dt_socket,address=8788,server=y,suspend=n"

  • to debug a server instance of your domain you have to pass jvm args in your host.xml, for example to debug server-one. I assume this must be the case, so more details provided in the blogs.

 

[0] - https://developer.jboss.org/thread/230399

[1] - https://stackoverflow.com/questions/26927082/wildfly-domain-mode-debug