jsr344-experts@javaserverfaces-spec-public.java.net

[jsr344-experts] 1137 non-servlet environment requirement

From: Neil Griffin <neil.griffin_at_portletfaces.org>
Date: Mon, 17 Dec 2012 19:12:31 -0500

Hi Ed,

The JSF 2.1 JavaDocs for ExternalContext#encodeNamespace(String) [1] indicate the following:

     * <p><em>Servlet:</em> The input value must be returned unchanged.</p>
     *
     * @param name Name to be encoded
     *
     * @throws NullPointerException if <code>name</code>
     * is <code>null</code>

Having said that, I would like to direct your attention to issue 1137 [2]. Although the issue is marked as "Open," the JSF 2.2 JavaDocs for ExternalContext have changed the throws requirement to the following:

     * @throws NullPointerException <span class="changed_modified_2_2">
     * if running in a non-servlet environment and <code>name</code> is
     * <code>null</code></span>.

Can you clarify as to why this requirement is now restricted to a non-servlet (portlet) environment? I think it might be best to simply remove this change from the JSF 2.2 JavaDocs and mark the 1137 issue as "WontFix".

Thanks,

Neil

[1] http://javaserverfaces.java.net/nonav/docs/2.1/javadocs/javax/faces/context/ExternalContext.html#encodeNamespace(java.lang.String)

[2] http://java.net/jira/browse/JAVASERVERFACES_SPEC_PUBLIC-1137