You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by de...@geronimo.apache.org on 2004/08/04 14:19:20 UTC

[jira] Assigned: (GERONIMO-260) NullPointerException deploying EAR files

Message:

   The following issue has been re-assigned.

   Assignee: Gianny DAMOUR (mailto:gianny_damour@hotmail.com)
---------------------------------------------------------------------
View the issue:
  http://issues.apache.org/jira/browse/GERONIMO-260

Here is an overview of the issue:
---------------------------------------------------------------------
        Key: GERONIMO-260
    Summary: NullPointerException deploying EAR files
       Type: Bug

     Status: Open
   Priority: Minor

    Project: Apache Geronimo
 Components: 
             deployment
   Versions:
             1.0-M2

   Assignee: Gianny DAMOUR
   Reporter: Eduardo Piva

    Created: Sat, 3 Jul 2004 11:42 AM
    Updated: Wed, 4 Aug 2004 5:18 AM
Environment: Linux kernel 2.6.7-rc3
JVM 1.4

Description:
When you have a META-INF/application.xml, with a module inside it, pointing to an invalid file, it causes NullPointerException. The following code fix that:

In EARConfigBuilder, package org.apache.geronimo.j2ee.deployment, method buildConfiguration, line 256, replace the following loop:

// each module installs it's files into the output context.. this is differenct for each module type

for (Iterator iterator = modules.iterator(); iterator.hasNext();) {
    Module module = (Module) iterator.next();
    getBuilder(module).installModule(earFile, earContext, module);
}

with
// each module installs it's files into the output context.. this is differenct for each module type

for (Iterator iterator = modules.iterator(); iterator.hasNext();) {
    Module module = (Module) iterator.next();
    URI moduleFile = module.getURI();

    if (!module.getURI().equals(URI.create("/")) && earFile.getEntry(moduleFile.toString()) == null) {
        throw new DeploymentException("Filename " + moduleFile + " not found");
    }

    getBuilder(module).installModule(earFile, earContext, module);
}

with that verification, we get a helpfull message inside a DeploymentException.



---------------------------------------------------------------------
JIRA INFORMATION:
This message is automatically generated by JIRA.

If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa

If you want more information on JIRA, or have a bug to report see:
   http://www.atlassian.com/software/jira