myfaces-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Daniel Bernstein (JIRA)" <...@myfaces.apache.org>
Subject [jira] Commented: (TOMAHAWK-201) Null pointer exception in org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRendererUtils.selectContentType
Date Tue, 21 Mar 2006 23:39:02 GMT
    [ http://issues.apache.org/jira/browse/TOMAHAWK-201?page=comments#action_12371344 ] 

Daniel Bernstein commented on TOMAHAWK-201:
-------------------------------------------

I do not see the problem using the myfaces examples.  Only when I'm starting my own app. 
I'm using standard j2ee authentication mechanisms.. Perhaps I have an unusual configuration.
 Here's a copy of my web xml:

<?xml version="1.0" encoding="UTF-8"?>
<!--
 * Copyright 2004 The Apache Software Foundation.
 *
 * Licensed 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 version="2.4" 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">
 <!-- This web.xml can be used during debugging, when there is no myfaces.jar
        library available.

        The faces-config.xml file (that is normally in the myfaces.jar) must be
        copied to the /WEB-INF directory of the web context.

        The TLDs (that are normally in the myfaces.jar) must be
        copied to the /WEB-INF/lib directory of the web context.-->
 <description>debug web.xml</description>
 <context-param>
  <description>Comma separated list of URIs of (additional) faces config files.
            (e.g. /WEB-INF/my-config.xml)
            See JSF 1.0 PRD2, 10.3.2</description>
  <param-name>javax.faces.CONFIG_FILES</param-name>
  <param-value>/WEB-INF/faces-config.xml</param-value>
 </context-param>
 <context-param>
  <description>State saving method: "client" or "server" (= default)
            See JSF Specification 2.5.2</description>
  <param-name>javax.faces.STATE_SAVING_METHOD</param-name>
  <param-value>server</param-value>
 </context-param>
 <context-param>
  <description>This parameter tells MyFaces if javascript code should be allowed in
the
            rendered HTML output.
            If javascript is allowed, command_link anchors will have javascript code
            that submits the corresponding form.
            If javascript is not allowed, the state saving info and nested parameters
            will be added as url parameters.
            Default: "true"</description>
  <param-name>org.apache.myfaces.ALLOW_JAVASCRIPT</param-name>
  <param-value>true</param-value>
 </context-param>
 <context-param>
  <description>If true, rendered HTML code will be formatted, so that it is "human readable".
            i.e. additional line separators and whitespace will be written, that do not
            influence the HTML code.
            Default: "true"</description>
  <param-name>org.apache.myfaces.PRETTY_HTML</param-name>
  <param-value>true</param-value>
 </context-param>
 <context-param>
  <param-name>tiles-definitions</param-name>
  <param-value>/WEB-INF/tiles.xml</param-value>
 </context-param>
 <context-param>
  <param-name>contextConfigLocation</param-name>
  <param-value>/WEB-INF/applicationContext*.xml</param-value>
 </context-param>
 <context-param>
  <param-name>archiveit-configuration</param-name>
  <param-value>/WEB-INF/configuration.properties</param-value>
 </context-param>
 <filter>
  <filter-name>securityFilter</filter-name>
  <filter-class>org.archive.servlet.SecurityContextFilter</filter-class>
 </filter>
 <filter>
  <filter-name>hibernateFilter</filter-name>
  <filter-class>org.archive.servlet.HibernateLongSessionFilter</filter-class>
 </filter>
 <filter>
  <filter-name>sessionFilter</filter-name>
  <filter-class>org.archive.servlet.SessionTrackingFilter</filter-class>
 </filter>
 <filter>
  <filter-name>MyFacesExtensionsFilter</filter-name>
  <filter-class>org.apache.myfaces.component.html.util.ExtensionsFilter</filter-class>
  <init-param>
   <param-name>maxFileSize</param-name>
   <param-value>20m</param-value>
  </init-param>
 </filter>


 <filter-mapping>
  <filter-name>MyFacesExtensionsFilter</filter-name>
  <servlet-name>Faces Servlet</servlet-name>

 </filter-mapping>


 <filter-mapping>
  <filter-name>MyFacesExtensionsFilter</filter-name>

  <url-pattern>/faces/myFacesExtensionResource/*</url-pattern>

 </filter-mapping>

 <filter-mapping>
  <filter-name>securityFilter</filter-name>
  <url-pattern>/secure/*</url-pattern>
 </filter-mapping>
 <filter-mapping>
  <filter-name>hibernateFilter</filter-name>
  <url-pattern>/secure/*</url-pattern>
 </filter-mapping>
 <filter-mapping>
  <filter-name>sessionFilter</filter-name>
  <url-pattern>/secure/*</url-pattern>
 </filter-mapping>




 <listener>
  <listener-class>org.springframework.web.context.ContextLoaderListener</listener-class>
 </listener>
 <listener>
  <listener-class>org.apache.myfaces.webapp.StartupServletContextListener</listener-class>
 </listener>
 <listener>
  <listener-class>org.xxx.SessionTrackingListener</listener-class>
 </listener>
 <servlet>
  <servlet-name>Feed Servlet</servlet-name>
  <servlet-class>org.xxx.FeedServlet</servlet-class>
  <load-on-startup>1</load-on-startup>
 </servlet>
 <servlet>
  <servlet-name>Faces Servlet</servlet-name>
  <servlet-class>javax.faces.webapp.FacesServlet</servlet-class>
  <load-on-startup>1</load-on-startup>
 </servlet>
 <servlet>
  <servlet-name>Report Servlet</servlet-name>
  <servlet-class>org.xxx.ReportServlet</servlet-class>
  <load-on-startup>1</load-on-startup>
 </servlet>
 <servlet-mapping>
  <servlet-name>Feed Servlet</servlet-name>
  <url-pattern>*.xml</url-pattern>
 </servlet-mapping>
 <servlet-mapping>
  <servlet-name>Faces Servlet</servlet-name>
  <url-pattern>*.faces</url-pattern>
 </servlet-mapping>
 <servlet-mapping>
  <servlet-name>Report Servlet</servlet-name>
  <url-pattern>*.report</url-pattern>
 </servlet-mapping>
 <session-config>
  <session-timeout>30</session-timeout>
 </session-config>
 <welcome-file-list>
  <welcome-file>index.jsp</welcome-file>
 </welcome-file-list>
 <jsp-config>
  <taglib>
   <taglib-uri>http://www.archive.org/extensions</taglib-uri>
   <taglib-location>ai-ext.tld</taglib-location>
  </taglib>
 </jsp-config>
 <security-constraint>
  <web-resource-collection>
   <web-resource-name>secure</web-resource-name>
   <url-pattern>/secure/*</url-pattern>
   <http-method>GET</http-method>
   <http-method>POST</http-method>
  </web-resource-collection>
  <auth-constraint>
   <role-name>*</role-name>
  </auth-constraint>
 </security-constraint>
 <login-config>
  <auth-method>FORM</auth-method>
  <form-login-config>
   <form-login-page>/login.jsp</form-login-page>
   <form-error-page>/login.jsp?error=1</form-error-page>
  </form-login-config>
 </login-config>
</web-app>


> Null pointer exception in org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRendererUtils.selectContentType
> ---------------------------------------------------------------------------------------------------------------
>
>          Key: TOMAHAWK-201
>          URL: http://issues.apache.org/jira/browse/TOMAHAWK-201
>      Project: MyFaces Tomahawk
>         Type: Bug
>     Versions: 1.1.2-SNAPSHOT
>  Environment: Linux, JBoss Head
>     Reporter: Arash Bijanzadeh

>
> I am getting a null pointer excetion in org.apache.myfaces.shared_tomahawk.renderkit.html.HtmlRendererUtils.selectContentType.
> The problemis my browser(Mozilla) do not send a accept header, abd the clas tryin to
get it.

-- 
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
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message