How to clean glassfish 4 cache and prevent deployment exceptions

When deploying an application to a glassfish server, some exception can appear in the administration console and server.log file: “org.glassfish.deployment.common.DeploymentException” or “java.lang.IllegalArgumentException: Could not find sub module [xxxxxxxx.war] as defined in application.xml

It will be very useful to clean the followings directories:

  • $GLASSFISH_HOME/glassfish/domains/domain1/generated/*
  • $GLASSFISH_HOME/glassfish/domains/domain1/osgi-cache/*
  • $GLASSFISH_HOME/glassfish/domains/domain1/applications/

Leave a Reply

Your email address will not be published. Required fields are marked *