RAD 7.0 "Archive is not a valid WAR" error

Filed under: Development, JSR168 Portals, WebSphere Portal — lars @ 11:42:31 am

I've had occasional errors over the years, in both IBM Rational Application Developer (RAD) 6.0 and 7.0, where a Portal WAR project in your workspace refuses to deploy to the portal test environment. Cleaning/refreshing projects, bouncing the portal test environment and even removing/re-adding the projects seems to make no difference.

The error you get (in System.err) is like this:

 *** ERROR ***: Tue May 15 17:14:40 BST 2007    com.ibm.etools.j2ee.commonarchivecore.exception.OpenFailureException:
IWAE0023E Unable to open module file "MyWar.war" in EAR file "C:\workspace\MyWarEAR"
!Stack_trace_of_nested_exce!
com.ibm.etools.j2ee.commonarchivecore.exception.OpenFailureException:
IWAE0006E Archive is not a valid WAR File because the deployment descriptor can not be found (case sensitive): WEB-INF/web.xml
at com.ibm.etools.j2ee.commonarchivecore.impl.CommonarchiveFactoryImpl.openSpecificArchive(CommonarchiveFactoryImpl.java:777)
at com.ibm.etools.j2ee.commonarchivecore.impl.CommonarchiveFactoryImpl.openWARFile(CommonarchiveFactoryImpl.java:802)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.openNestedArchive(EARFileImpl.java:644)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.openNestedArchive(EARFileImpl.java:609)
at com.ibm.etools.j2ee.commonarchivecore.strategy.LoadStrategyImpl.openNestedArchive(LoadStrategyImpl.java:454)
at com.ibm.etools.j2ee.commonarchivecore.strategy.LoadStrategyImpl.collectFilesFromLooseArchives(LoadStrategyImpl.java:291)
at com.ibm.etools.j2ee.commonarchivecore.strategy.LoadStrategyImpl.collectFiles(LoadStrategyImpl.java:271)
at com.ibm.etools.j2ee.commonarchivecore.impl.ContainerImpl.getFiles(ContainerImpl.java:221)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getModuleFiles(EARFileImpl.java:476)
at com.ibm.ws.webservices.deploy.DeployUtils.isWebServicesSecurityEnabled(DeployUtils.java:718)
at com.ibm.ws.webservices.deploy.WSDeployTask.performTask(WSDeployTask.java:97)
at com.ibm.ws.management.application.SchedulerImpl.run(SchedulerImpl.java:253)
at java.lang.Thread.run(Thread.java:570)
[15/05/07 17:14:41:314 BST] 0000005a SystemErr R com.ibm.etools.j2ee.commonarchivecore.exception.DeploymentDescriptorLoadException:
IWAE0022E Exception occurred loading deployment descriptor for module "MyWarWAR.war" in EAR file
"C:\workspace\MyWartEAR"
!Stack_trace_of_nested_exce!
com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException: A file does not exist for module element having uri: MyWar.war
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.checkType(ModuleRefImpl.java:492)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.initModuleFileFromEAR(ModuleRefImpl.java:120)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.getModuleFile(ModuleRefImpl.java(Compiled Code))
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getModuleFile(EARFileImpl.java:90)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getDeploymentDescriptor(EARFileImpl.java:322)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getDeploymentDescriptor(EARFileImpl.java:330)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.rollUpRoles(EARFileImpl.java:785)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.rollUpRoles(EARFileImpl.java:775)
at com.ibm.websphere.management.application.client.ArchiveDeploymentInfo.<init>(ArchiveDeploymentInfo.java:150)
at com.ibm.ws.management.application.client.AppInstallHelper.getAppDeploymentInfo(AppInstallHelper.java:184)
at com.ibm.ws.management.application.client.AppInstallHelper.getAppDeploymentInfo(AppInstallHelper.java:178)
at com.ibm.ws.management.application.task.ValidateAppTask.performTask(ValidateAppTask.java:106)
at com.ibm.ws.management.application.SchedulerImpl.run(SchedulerImpl.java:253)
at java.lang.Thread.run(Thread.java:570)

[15/05/07 17:14:41:314 BST] 0000005a SystemErr R !Stack_trace_of_nested_exce!
[15/05/07 17:14:41:314 BST] 0000005a SystemErr R com.ibm.etools.j2ee.commonarchivecore.exception.NoModuleFileException:
A file does not exist for module element having uri: MyWar.war
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.checkType(ModuleRefImpl.java:492)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.initModuleFileFromEAR(ModuleRefImpl.java:120)
at com.ibm.etools.j2ee.commonarchivecore.impl.ModuleRefImpl.getModuleFile(ModuleRefImpl.java(Compiled Code))
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getModuleFile(EARFileImpl.java:90)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getDeploymentDescriptor(EARFileImpl.java:322)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.getDeploymentDescriptor(EARFileImpl.java:330)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.rollUpRoles(EARFileImpl.java:785)
at com.ibm.etools.j2ee.commonarchivecore.impl.EARFileImpl.rollUpRoles(EARFileImpl.java:775)
at com.ibm.websphere.management.application.client.ArchiveDeploymentInfo.<init>(ArchiveDeploymentInfo.java:150)
at com.ibm.ws.management.application.client.AppInstallHelper.getAppDeploymentInfo(AppInstallHelper.java:184)
at com.ibm.ws.management.application.client.AppInstallHelper.getAppDeploymentInfo(AppInstallHelper.java:178)
at com.ibm.ws.management.application.task.ValidateAppTask.performTask(ValidateAppTask.java:106)
at com.ibm.ws.management.application.SchedulerImpl.run(SchedulerImpl.java:253)
at java.lang.Thread.run(Thread.java:570)

Today, I seemed to be able to fix this by stoping the portal v6.0 test environment, closing RAD, then deleting this project's directory in:

C:\workspace\.metadata\.plugins\org.eclipse.wst.server.core\tmp0

I then restarted RAD/Portal test-env, redeployed the app to my portal test environment and the error was gone. 

Comments

  • David Faulkner
    This link: http://www-1.ibm.com/support/docview.wss?uid=swg21255956 directs to another possible solution if the one above does not work for you.

    Comment by David Faulkner [Visitor] — 12/18/07 @ 08:40

  • Lars
    Thanks for your comments David. I just had this happen to me again, in a non-portal environment running RAD 6.0.1.2. Unfortunately your link seems to be RAD 7.0 specific, but I was able to fix it in this instance by:

    1. Removing the application from the server via RAD's 'Add and remove projects...'
    2. restarting RAD
    3. doing a right-click -> refresh of all projects
    4. Project -> Clean... -> All Projects
    5. Starting the server and re-adding the project.

    Comment by Lars [Visitor] — 06/06/08 @ 10:59

Leave a comment

Allowed XHTML tags: <p, ul, ol, li, dl, dt, dd, address, blockquote, ins, del, span, bdo, br, em, strong, dfn, code, samp, kdb, var, cite, abbr, acronym, q, sub, sup, tt, i, b, big, small>


Options:
(Line breaks become <br />)
(Set cookies for name, email & url)




powered by  b2evolution