glassfish "Could not find sub module [business-web-1.0-SNAPSHOT.war] as defined in application.xml"

StackOverflow https://stackoverflow.com/questions/15485649

Question

application.xml

<?xml version="1.0" encoding="UTF-8"?>
<application xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/application_6.xsd" version="6">
  <display-name>business-ear</display-name>
  <module>
    <web>
      <web-uri>business-web-1.0-SNAPSHOT.war</web-uri>
      <context-root>business</context-root>
    </web>
  </module>
</application>

filepath c:\glassfish3\glassfish\domains\domain1\autodeploy\business.ear\

structure business.ear ->

META-INF business-web-1.0-SNAPSHOT.war

please, help me!

Was it helpful?

Solution

I'm having this issue also I start getting it after I upgraded to the version 3.1.2.2. I have a solution but it sometimes happens that this error appears again, I believe it's related to Glassfish holding stale app data.

  1. Go to your glassfish domain folder -> glassfish3\glassfish\domains\domain1\applications\

  2. Check inside your applications folder and inside your app folder you will find a file called ".glassfishStaleFiles"

  3. Open this file with a text editor, see which jar library Glassfish has listed on the last line of the file.

  4. Update this dependency (using maven or other tool)

  5. clean the applications folder.

  6. Build everything again.

Hope this helps

OTHER TIPS

Delete manually all the subfolders of the "applications" folder

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top