You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@geronimo.apache.org by "Jarek Gawor (JIRA)" <ji...@apache.org> on 2007/11/20 05:07:43 UTC
[jira] Created: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
JNDI lookup problem on fowarded calls in Jetty
----------------------------------------------
Key: GERONIMO-3609
URL: https://issues.apache.org/jira/browse/GERONIMO-3609
Project: Geronimo
Issue Type: Bug
Security Level: public (Regular issues)
Components: Jetty
Affects Versions: 2.0.x, 2.1
Reporter: Jarek Gawor
I am having trouble looking up a DataSource from an EAR containing a
WAR (which is where the lookup takes place) using JNDI. I find it to
be really weird, because I can look up the DataSource fine if I do it
through a JSP page or a servlet. However, when I try to look it up in
portlet code, the jndi name does not seem to be visible, although it
is visible in the JNDI viewer. Additionally, I have successfully
looked it up through jsp and servlets.
This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Jencks closed GERONIMO-3609.
----------------------------------
Resolution: Fixed
The patch seems to work and ith the other new uses of LifecycleMethod I don't think the code can be simplified more so I committed it in rev 601149.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Fix For: 2.1
>
> Attachments: GERONIMO-3609-2.patch, GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "Jarek Gawor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12543772 ]
Jarek Gawor commented on GERONIMO-3609:
---------------------------------------
First, we are dealing with two different web application
contexts (/console and /MonitoringPortlet) and both web app contexts
have different JNDI trees with different resources. The console is
basically forwarding a request from /console to /MonitoringPortlet. It
looks like on Jetty when a request is forwarded from one context to
another, the JNDI tree associated with the current thread does NOT
change for the duration of the call. That means, when a monitoring
portlet looks for resources in JNDI it actaully gets /console JNDI
tree instead of its own.
Your portlet works on Tomcat as Tomcat appears to be properly
switching the JNDI trees during the call.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Closed: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Jencks closed GERONIMO-3609.
----------------------------------
Resolution: Fixed
Fix Version/s: 2.1
Fixed in rev 598410 with solution from patch but also removing duplicate context handler. We should keep our eyes open for problems this might cause...
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Fix For: 2.1
>
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "Jarek Gawor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12545572 ]
Jarek Gawor commented on GERONIMO-3609:
---------------------------------------
Ok, thanks. I just checked in a test case for this issue under testsuite/web-testsuite/test-web-forward (revision 598396). Will hook it up to the rest of the testsuite later.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "Jarek Gawor (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Jarek Gawor updated GERONIMO-3609:
----------------------------------
Attachment: GERONIMO-3609.patch
Proposed fix for this issue.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Assigned: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Jencks reassigned GERONIMO-3609:
--------------------------------------
Assignee: David Jencks
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Commented: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12545548 ]
David Jencks commented on GERONIMO-3609:
----------------------------------------
Proposed fix will work but I think it introduces duplication that we can remove.... checking it out.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Reopened: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Jencks reopened GERONIMO-3609:
------------------------------------
Fix seems to have removed jndi from servlet listeners.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Fix For: 2.1
>
> Attachments: GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.
[jira] Updated: (GERONIMO-3609) JNDI lookup problem on fowarded
calls in Jetty
Posted by "David Jencks (JIRA)" <ji...@apache.org>.
[ https://issues.apache.org/jira/browse/GERONIMO-3609?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
David Jencks updated GERONIMO-3609:
-----------------------------------
Attachment: GERONIMO-3609-2.patch
Possible approach for getting jndi in the right places. This is completely untested, all I know is it compiles for me.
> JNDI lookup problem on fowarded calls in Jetty
> ----------------------------------------------
>
> Key: GERONIMO-3609
> URL: https://issues.apache.org/jira/browse/GERONIMO-3609
> Project: Geronimo
> Issue Type: Bug
> Security Level: public(Regular issues)
> Components: Jetty
> Affects Versions: 2.0.x, 2.1
> Reporter: Jarek Gawor
> Assignee: David Jencks
> Fix For: 2.1
>
> Attachments: GERONIMO-3609-2.patch, GERONIMO-3609.patch
>
>
> I am having trouble looking up a DataSource from an EAR containing a
> WAR (which is where the lookup takes place) using JNDI. I find it to
> be really weird, because I can look up the DataSource fine if I do it
> through a JSP page or a servlet. However, when I try to look it up in
> portlet code, the jndi name does not seem to be visible, although it
> is visible in the JNDI viewer. Additionally, I have successfully
> looked it up through jsp and servlets.
> This is only a problem in Jetty, because the same code works fine for Tomcat.
--
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.