XNSIO
  About   Slides   Home  

 
Managed Chaos
Naresh Jain's Random Thoughts on Software Development and Adventure Sports
     
`
 
RSS Feed
Recent Thoughts
Tags
Recent Comments

Contents of MANIFEST files being cleared by WsEjbDeploy target

Recently on our project, we ran into a weird issue with the contents of the Manifest files being cleared out after passing the jar, containing the manifest file, to the com.ibm.websphere.ant.tasks.WsEjbDeploy task or wsejbdeploy target.

Following are the contents of the

Manifest-Version: 1.0
Class-Path: log4j.jar
fit.jar
fitdecorator.jar
junit.jar

After analyzing the issue we discovered the following regarding the format and contents of the manifest files that are expected by the webshpere‘s wsejbdeploy target
1. The manifest file should always end with a new line. No spaces or special characters are allowed on this last line. Else the contents of the manifest file will be cleared. (We had a new line, but by mistake it had a space in the beginning)
2. For the class-path, you could choose to have one jar per line or a space separated listed of jars. But if you choose the first option for readability then:
a. Each line should begin with a space followed by the jar name. Else will result in the following error
com.ibm.websphere.management.application.client.AppDeploymentException: AppDeploymentException: [null]
[exec] com.ibm.etools.j2ee.commonarchivecore.exception.DeploymentDescriptorLoadException: com.ibm.etools.j2ee.commonarchivecore.exception.DeploymentDescriptorLoadException: IWAE0022E Exception occurred loading deployment descriptor for module “XXX.jar“ in EAR file “C:\Documents and Settings\username\Local Settings\Temp\app39696.ear”
b. Each line should end with a space, else it will collapse the subsequent jars on the same line without a space in between and will result in wrong jar names

For some basic understanding of manifest files visit the following link:
http://java.sun.com/j2se/1.4.2/docs/guide/jar/jar.html


    Licensed under
Creative Commons License