[
https://jira.jboss.org/jira/browse/GTNPC-19?page=com.atlassian.jira.plugi...
]
Julien Viet commented on GTNPC-19:
----------------------------------
Looking at the Portlet 1.0 XSD I read:
<choice>
<sequence>
<element name="resource-bundle"
type="portlet:resource-bundleType"/>
<element name="portlet-info" type="portlet:portlet-infoType"
minOccurs="0"/>
</sequence>
<element name="portlet-info" type="portlet:portlet-infoType"/>
</choice>
that implies to me (but it is my personal opinion) that either
1/ the developer provides a portlet-info section that will have a title and we do have a
title
2/ the developers can ommit the portlet-info section but has to provide a resource bundle
that will contain the title
In that case your test case:
<portlet>
<portlet-name>UniversalTestPortletB</portlet-name>
<portlet-class>org.gatein.pc.test.portlet.framework.UTP1</portlet-class>
<supports>
<mime-type>text/html</mime-type>
</supports>
</portlet>
is not a valid deployment descriptor
I think that a valid unit test for that would be the same XML but with a resource bundle
pointing to an empty bundle. And in that case the error would remain as it would have the
meaning of having the same error than the empty XML.
In both situation we should raise an error a deployment time and not accomodate the
runtime to fix the deployment time issue.
does it make sense to you ?
No portlet info section in portlet.xml leads to display a portlet
error
-----------------------------------------------------------------------
Key: GTNPC-19
URL:
https://jira.jboss.org/jira/browse/GTNPC-19
Project: GateIn Portlet Container
Issue Type: Bug
Reporter: Julien Viet
Assignee: Matt Wringe
Attachments: pc-empty-portlet-info.patch
java.util.MissingResourceException: Can't find resource for bundle
org.gatein.common.i18n.ParentChildResourceBundle, key javax.portlet.title
at java.util.ResourceBundle.getObject(ResourceBundle.java:325)
at java.util.ResourceBundle.getString(ResourceBundle.java:285)
at javax.portlet.GenericPortlet.getTitle(GenericPortlet.java:261)
at javax.portlet.GenericPortlet.render(GenericPortlet.java:232)
at
org.gatein.pc.portlet.impl.jsr168.PortletContainerImpl$Invoker.doFilter(PortletContainerImpl.java:569)
at
org.gatein.pc.portlet.impl.jsr168.api.FilterChainImpl.doFilter(FilterChainImpl.java:159)
at
org.gatein.pc.portlet.impl.jsr168.api.FilterChainImpl.doFilter(FilterChainImpl.java:80)
at
org.gatein.pc.portlet.impl.jsr168.PortletContainerImpl.dispatch(PortletContainerImpl.java:506)
at
org.gatein.pc.portlet.container.ContainerPortletDispatcher.invoke(ContainerPortletDispatcher.java:42)
followed by
java.lang.NullPointerException
at
org.exoplatform.portal.webui.application.UIPortletLifecycle.processRender(UIPortletLifecycle.java:293)
at
org.exoplatform.portal.webui.application.UIPortletLifecycle.processRender(UIPortletLifecycle.java:61)
at org.exoplatform.webui.core.UIComponent.processRender(UIComponent.java:148)
at org.exoplatform.webui.core.UIContainer.renderChildren(UIContainer.java:368)
at org.exoplatform.webui.core.UIContainer.renderChildren(UIContainer.java:358)
--
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
https://jira.jboss.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
http://www.atlassian.com/software/jira