Hi All,
I'm having trouble integrating Acegi 1.0.0 with RHEL 5, using
tomcat5-5.5.23-0jpp.1.0.3.el5. In windows, it just works fine, no problems
at all. The java version that I'm running is as follows:

# whereis java
java: /usr/bin/java /etc/java /usr/lib/java /usr/share/java

# /usr/bin/java -version
java version "1.4.2"
gij (GNU libgcj) version 4.1.1 20070105 (Red Hat 4.1.1-52)

I've also attached a copy of the web.xml.

Tomcat is complaining that it has an error configuring the Acegi's
HttpSessionEventPublisher context listener defined correctly in the WEB.XML,
due to a NullpointerException.
I suspect that there's an incompatibility with the libgcj and the context
class loader.

To further isolate the problem, I have created a simple test class that
implements the HttpSessionListener and it loaded it with no problem, and
also other context listeners loaded with no problems. This confirms that it
does not have problem loading Context Listener of types other than Acegi in
general. In addition, I've also disabled SELinux.

Does anybody knows what the issue is with this ?
Any help here would be greatly appreciated. Thanks very much!

Here's the stack trace:

[ERROR,[/webpay],main] Error configuring application listener of class
org.acegisecurity.ui.session.HttpSessionEventPublisher
java.lang.NullPointerException
  at java.lang.VMClassLoader.defineClass(libgcj.so.7rh)
  at java.lang.ClassLoader.defineClass(libgcj.so.7rh)
  at java.security.SecureClassLoader.defineClass (libgcj.so.7rh)
  at java.net.URLClassLoader.findClass(libgcj.so.7rh)
  at gnu.gcj.runtime.BootClassLoader.bootLoadClass(libgcj.so.7rh)
  at java.lang.VMClassLoader.loadClass(libgcj.so.7rh)
  at java.lang.ClassLoader.loadClass (libgcj.so.7rh)
  at java.lang.ClassLoader.loadClass(libgcj.so.7rh)
  at java.lang.ClassLoader.loadClass(libgcj.so.7rh)
  at 
org.apache.catalina.loader.WebappClassLoader.loadClass(catalina-5.5.23.jar.so
)
  at org.apache.catalina.loader.WebappClassLoader.loadClass(
catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardContext.listenerStart (
catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardContext.start(catalina-5.5.23.jar.so)
  at org.apache.catalina.core.ContainerBase.addChildInternal (
catalina-5.5.23.jar.so)
  at org.apache.catalina.core.ContainerBase.addChild(catalina-5.5.23.jar.so
)
  at org.apache.catalina.core.StandardHost.addChild (catalina-5.5.23.jar.so
)
  at org.apache.catalina.startup.HostConfig.deployWAR(
catalina-5.5.23.jar.so)
  at org.apache.catalina.startup.HostConfig.deployWARs (
catalina-5.5.23.jar.so)
  at org.apache.catalina.startup.HostConfig.deployApps(
catalina-5.5.23.jar.so)
  at org.apache.catalina.startup.HostConfig.start (catalina-5.5.23.jar.so)
  at org.apache.catalina.startup.HostConfig.lifecycleEvent(
catalina-5.5.23.jar.so)
  at org.apache.catalina.util.LifecycleSupport.fireLifecycleEvent (
catalina-5.5.23.jar.so)
  at org.apache.catalina.core.ContainerBase.start(catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardHost.start (catalina-5.5.23.jar.so)
  at org.apache.catalina.core.ContainerBase.start(catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardEngine.start (catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardService.start(catalina-5.5.23.jar.so)
  at org.apache.catalina.core.StandardServer.start (catalina-5.5.23.jar.so)
  at org.apache.catalina.startup.Catalina.start(catalina-5.5.23.jar.so)
  at java.lang.reflect.Method.invoke (libgcj.so.7rh)
  at org.apache.catalina.startup.Bootstrap.start(bootstrap.jar.so)
  at org.apache.catalina.startup.Bootstrap.main(bootstrap.jar.so )

[ERROR,[/webpay],main] Skipped installing application listeners due to
previous error(s)
21-Jun-07 2:21:49 AM org.apache.catalina.core.StandardContext start
SEVERE: Error listenerStart
<?xml version="1.0" encoding="ISO-8859-1"?>
<!--
 Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->

<web-app xmlns="http://java.sun.com/xml/ns/j2ee";
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
    xsi:schemaLocation="http://java.sun.com/xml/ns/j2ee http://java.sun.com/xml/ns/j2ee/web-app_2_4.xsd";
    version="2.4">

  <display-name>Webdav Content Management</display-name>
  <description>
     Webdav Content Management
  </description>

  <servlet>
    <servlet-name>webdav</servlet-name>
    <servlet-class>org.apache.catalina.servlets.WebdavServlet</servlet-class>
    <init-param>
      <param-name>debug</param-name>
      <param-value>0</param-value>
    </init-param>
    <init-param>
      <param-name>listings</param-name>
      <param-value>true</param-value>
    </init-param>
    <!-- Uncomment this to enable read and write access -->
<!--
    <init-param>
      <param-name>readonly</param-name>
      <param-value>false</param-value>
    </init-param>
-->
    <!--load-on-startup>1</load-on-startup-->
  </servlet>

  <!-- The mapping for the webdav servlet -->
  <!-- Using /* as the mapping ensures that jasper, welcome files etc are
       over-ridden and all requests are processed by the webdav servlet.
       This also overcomes a number of issues with some webdav clients
       (including MS Webfolders) that do not respond correctly
 to the
       redirects (302) that result from using a mapping of / -->
  <servlet-mapping>
    <servlet-name>webdav</servlet-name>
    <url-pattern>/*</url-pattern>
  </servlet-mapping>

  <!-- ================ Security Constraints for Testing =============== -->

<!--
  <security-constraint>
    <web-resource-collection>
      <web-resource-name>The Entire Web Application</web-resource-name>
      <url-pattern>/*</url-pattern>
    </web-resource-collection>
    <auth-constraint>
      <role-name>tomcat</role-name>
    </auth-constraint>
  </security-constraint>

  <login-config>
    <auth-method>BASIC</auth-method>
    <realm-name>Tomcat Supported Realm</realm-name>
  </login-config>

  <security-role>
    <description>
      An example role defined in "conf/tomcat-users.xml"
    </description>
    <role-name>tomcat</role-name>
  </security-role>
-->

  <welcome-file-list>
    <welcome-file/>
  </welcome-file-list>  

</web-app>
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
_______________________________________________
Home: http://acegisecurity.org
Acegisecurity-developer mailing list
Acegisecurity-developer@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/acegisecurity-developer

Reply via email to