PQ65763: ADD EXTENDED DOCUMENT ROOT CAPABILITY FOR WEBAPPS | |||||||||||||||||||||||||||||||||||||||
![]() |
|||||||||||||||||||||||||||||||||||||||
![]() APAR status Closed as program error. Error description The current implementation of WAS cannot serve JSPs from web applications that store JSPs in JAR files. WAS expects to locate JSPs on the file system inside the war. The customer packages their JSPs in JARs that are accessible on the application's classpath,and expects the WAS JSP processor to serve them.Local fix Package and deploy all JSPs such that they are distinct files located on the file system inside of the war file.Problem summary **************************************************************** * USERS AFFECTED: WebSphere Application Server installations * * that need the ability to share resources * * across multiple web applications. * **************************************************************** * PROBLEM DESCRIPTION: Customer has JSP and static resources * * that are common to a variety of web * * applications and would like to install * * only one copy of each resource on a * * machine. * **************************************************************** * RECOMMENDATION: * **************************************************************** WebSphere follows the J2EE model for deploying web applications which suggests that all resources should be contained within a web application archive (WAR) structure. Since customers may have applications that contain reusable JSP and static resources, customers are required to place copies of each of these resources inside of each WAR. This prevents easy maintenance of common JSPs and other static resources.Problem conclusion To allow a resource (JSP and static) to be shared, WebSphere has created servlet initialization parameters for both the FileServingEnabler and JSP Processor which allows the developer to specify a comma delimited list of directories and/or jar files as search paths if the requested resource cannot be located in the web application archives public document tree. ================================================== This behavior can be enabled via the Application Assembly Tool (AAT). 1) Open enterprise application archive (EAR) inside AAT. 2) Expand Web Modules 3) Expand selected Web Module 4) Expand Assembly Property Extensions 5) Right mouse click on JSP Attributes or File Serving Attributes (depending upon which you choose to use) 6) Select New 7) option 1. name = extendedDocumentRoot value = someResource.jar (relative to webapp archive). option 2. name = extendedDocumentRoot value = c:/sharedDir/someResource.jar (absolute reference). Note that value accepts a comma separated list that can mix both option 1 and option 2. The following is a sample ibm-web-ext.xmi file demonstrating how this feature is enabled for an application that has already been deployed. parameter name = extendedDocumentRoot parameter value = web application archive relative or absolute path to resource. <webappext:WebAppExtension xmi:version="2.0" xmlns:xmi="http://www.omg.org/XMI" xmlns:webappext="webappext.xmi" xmlns:webapplication="webapplication.xmi" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmi:id="WebAppExtension_2" reloadInterval="5" reloadingEnabled="true" defaultErrorPage="error.jsp" additionalClassPath="" fileServingEnabled="true" directoryBrowsingEnabled="true" serveServletsByClassnameEnabled="true"> <webApp href="WEB-INF/web.xml#WebApp_ID"/> <jspAttributes xmi:id="JSPAttribute_1" name="keepgenerated" value="true"/> <jspAttributes xmi:id="JSPAttribute_2" name="largefile" value="false"/> <jspAttributes xmi:id="JSPAttribute_3" name="extendedDocumentRoot" value="testcase.jar, c:/shared/my-test.jar, my-test.war/WEB-INF/lib/war_level.jar"/> <fileServingAttributes xmi:id="FileServingAttribute_1" name="extendedDocumentRoot" value="testcase.jar, c:/shared/my-test.jar, my-test.war/WEB-INF/lib/war_level.jar"/> </webappext:WebAppExtension> NOTE: Line item 1657 1911 2164 LIDB1657 LIDB1911 LIDB2164Temporary fix //wasdoc0/apars/pq65763/4.0.4Comments
APAR is sysrouted FROM one or more of the following: APAR is sysrouted TO one or more of the following: PQ68502 Modules/Macros
SRLS
|
Document Information |
Product categories: Software > Application Servers >
Distributed Application & Web Servers > WebSphere Application
Server > General
Operating system(s):
Software version: 400
Software edition:
Reference #: PQ65763
IBM Group: Software Group
Modified date: Nov 22, 2002
(C) Copyright IBM Corporation 2000, 2006. All Rights Reserved.