[
https://issues.apache.org/jira/browse/GERONIMO-5405?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Han Hong Fang updated GERONIMO-5405:
------------------------------------
Attachment: Geronimo-5405.patch
Patch for this problem is uploaded. Please help to review, thanks!
Here is the implementation details. According to servlet 3.0 spec quoted
below, in Geronimo, getRealPath()
- return the unpacked location for the resources located in the
META-INF/resources directory of the jar file
- for all other situation it returns null.
If same resources exist in different jar files, getRealPath() return the
location once resource with specified name is found in one of the jar file.
P.S.
Servlet 3.0 Spec quotation:
"In situations where the servlet container cannot determine a valid file path
for these
methods, such as when the Web application is executed from an archive, on a
remote
file system not accessible locally, or in a database, these methods must return
null.
Resources inside the META-INF/resources directory of JAR file must be
considered only if the container has unpacked them from their containing JAR
file
when a call to getRealPath() is made, and in this case MUST return the unpacked
location."
> In servlet, getServletConfig().getServletContext().getRealPath("/") return
> null
> -------------------------------------------------------------------------------
>
> Key: GERONIMO-5405
> URL: https://issues.apache.org/jira/browse/GERONIMO-5405
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Affects Versions: 3.0-M1, 3.0
> Reporter: Forrest Xia
> Assignee: Han Hong Fang
> Attachments: Geronimo-5405.patch
>
>
> In the OSGi environment, no expanded web app directories in the geronimo
> repository, so we need a way to get the resource within jar/war/ear/car.
> This bug causes daytrader app cannot initialize the database tables from the
> enclosed sql file.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.