ode-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Douglas Scott Jackson (JIRA)" <j...@apache.org>
Subject [jira] Commented: (ODE-239) Ode server fails with null pointer exception when war is deployed inside an ear file in weblogic
Date Tue, 05 Feb 2008 15:52:08 GMT

    [ https://issues.apache.org/jira/browse/ODE-239?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12565777#action_12565777
] 

Douglas Scott Jackson commented on ODE-239:
-------------------------------------------

A further advantage of allowing for a system property to configure the working directory
might be for clustering so that deploying to one ode deploys to all if more than 1 ode
points to the same directory (shared filesystem).



> Ode server fails with null pointer exception when war is deployed inside an ear file
in weblogic
> ------------------------------------------------------------------------------------------------
>
>                 Key: ODE-239
>                 URL: https://issues.apache.org/jira/browse/ODE-239
>             Project: ODE
>          Issue Type: Bug
>          Components: Axis2 Integration
>    Affects Versions: 1.2
>            Reporter: Douglas Scott Jackson
>
> I dropped the ode.war inside an ear file since we may wish to deploy it as part of our
application.
> When I did so, I got a NullPointerException.  
> The expression config.getServletContext().getRealPath("/WEB-INF") evaluated to null.
> I would like to propose a fix like the following:
> Index: axis2/src/main/java/org/apache/ode/axis2/ODEServer.java
> ===================================================================
> --- axis2/src/main/java/org/apache/ode/axis2/ODEServer.java     (revision 615241)
> +++ axis2/src/main/java/org/apache/ode/axis2/ODEServer.java     (working copy)
> @@ -115,7 +115,12 @@
>          boolean success = false;
>          try {
>              _axisConfig = axisConf;
> -            _appRoot = new File(config.getServletContext().getRealPath("/WEB-INF"));
> +            String workingDir = System.getProperty("org.apache.ode.workingDir");
> +            if (workingDir != null)
> +               _appRoot = new File(workingDir);
> +            else
> +               _appRoot = new File(config.getServletContext().getRealPath("/WEB-INF"));
> +
>              TempFileManager.setWorkingDirectory(_appRoot);
>              __log.debug("Loading properties");

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


Mime
View raw message