AEM in Debug Mode

To start the AEM in debug mode, start the server with the below command

java -jar aem-author-p4502.jar -debug 45024

  • -debug is used to start the server in the debug mode 
  • 40524 is the debug port
Once the server is up and running, Configure the debug configurations in your IDE (Eclipse, etc..)

For Eclipse:
  • Click on Debug Configurations from the Debug Menu
  • Create a new "Remote Java Application"
  • Enter the details as below:
           Name: sampleproject
           Project: sampleproject.core
           Host: localhost
           Port: 45024 (Same port as the AEM instance has run on the debug mode)
  • Apply the changes and Click on Debug

Once the above configurations are completed, add a break point in any service/model/utility class.

when we try to refresh the page where the respective service is being called, Debug mode will be started/triggered in eclipse.


Congratulations on starting your AEM instance in Debug mode. Happy Debugging!!!


Comments

Popular posts from this blog

Delete DAM Asset using Workflow

Groovy Console Integration and executing scripts in AEM

AEM Project Maven Build - Easy setup and steps to run commands via command line