Details
-
Bug
-
Status: Closed
-
Major
-
Resolution: Fixed
-
unspecified
-
None
-
JBoss 3.2.5
Description
The portal is not able to find portlets if these are deployed in an uncompressed directory containing a .war suffix. The problem is with the resolveURI(String) method found within the org.apache.pluto.portalImpl.services.portletdefinitionregistry.PortletDefinitionRegistryServiceFileImpl class. The code only considers the case when portlets are deployed as compressed WAR files.
The following code fixes the problem:
private String resolveURI(String webModule)
{
// For JBoss compatibility, change webModule from the form
// of "tmp12345foo.war" to "foo".
int len = webModule.length();
if (webModule.endsWith(WAR_FILE_EXT) &&
webModule.startsWith(INITIAL_TMP_PREFIX) &&
len > FULL_TMP_PREFIX_LEN + WAR_FILE_EXT.length())
else if (webModule.endsWith(WAR_FILE_EXT))
{ webModule = webModule.substring(0, len - WAR_FILE_EXT.length()); } // else assumed literal.
return webModule;
}
Thanks.