RequestDispatcher.forward() bug in WLS61???

Hi
          attached is a web application called forward that demonstrate a possible
          bug in weblogic 6.1 server.
          Description of the application
          index.html:
          <html>
          <head>
          <title>form</title>
          </head>
          <body>
          <form name="form" method="post" action="forwardServlet">
          <input type="hidden" name="nextPage" size="20"
          value="result.jsp">
          </form>
          <script language="javascript">
          document.forms["form"].submit();
          </script>
          </body>
          </html>
          the index.html of the application just cause the web browser to send a
          request to the ForwardServlet with a parameter nextPage=result.jsp
          ForwardServlet.java:
          import javax.servlet.http.*;
          import javax.servlet.*;
          import java.io.*;
          public class ForwardServlet extends HttpServlet {
          public void service(HttpServletRequest request,
          HttpServletResponse response) throws ServletException,
          IOException {
          RequestDispatcher disp =
          getServletContext().getRequestDispatcher("/" +
          request.getParameter("nextPage") + "?result=kabooom");
          disp.forward(request, response);
          the servlet forwards the request to the nextPage(result.jsp) using
          RequestDispatcher.forward adding to the URI a parameter result=kabooom;
          result.jsp:
          ****<P>
          <%
          String result = request.getParameter("result");
          out.println(result);
          %>
          <P>****
          the jsp just takes the "result" parameter from the request object and
          prints it. However it gets a null instead of the String kaboom
          We use this method of adding parameters in many places in our application
          and it should work according to the API:
          "For a RequestDispatcher obtained via getRequestDispatcher(), the
          ServletRequest object has its path elements and parameters adjusted to match
          the path of the target resource."
          Everything worked fine in WLS5.1
          P.S
          if ForwardServlet.java looks like:
          import javax.servlet.http.*;
          import javax.servlet.*;
          import java.io.*;
          public class ForwardServlet extends HttpServlet {
          public void service(HttpServletRequest request,
          HttpServletResponse response) throws ServletException,
          IOException {
          RequestDispatcher disp =
          getServletContext().getRequestDispatcher("/result.jsp?result=kabooom");
          disp.forward(request, response);
          and not touching the request object itself the result.jsp will display
          kaboom!!!!
          Dror Last
          Senior Software Engineer
          Unisfair Inc.
          12 Yad Haruzim St. Tel Aviv 67778 Israel
          Tel: +972-3-5373738 Ext. 243
          Fax: +972-3-5373731
          GSM: +972-55-723710
          mailto:[email protected]
          http://www.unisfair.com/
          [forward.war]
          

Yes, SP1 fixes the problem.
          Thanks,
          Beth
          "Ian M. Goldstein" <[email protected]> wrote in message
          news:[email protected]...
          > Service Pack 1 is available now via WebSupport
          > http://websupport.beasys.com/custsupp/
          >
          > Regards,
          > -- Ian
          >
          > "Robert Patrick" <[email protected]> wrote in message
          > news:[email protected]...
          > > Contact BEA technical support...
          > >
          > > Beth wrote:
          > >
          > > > Hi,
          > > >
          > > > We are having this same problem with WL6.1.
          > > > Where do we get this patch? It doesn't appear that SP1 is out yet.
          > > >
          > > > Thanks,
          > > > Beth
          > > >
          > > > "Andrew" <[email protected]> wrote in message
          > > > news:[email protected]...
          > > > >
          > > > > I spoke with BEA about this bug, as we were exhibiting almost the
          > exact
          > > > same behavior.
          > > > > It is definitely a bug, and their engineering department said it is
          > fixed
          > > > with
          > > > > 6.1 SP1 which is due to be released in September. They gave me a
          > patch to
          > > > test,
          > > > > and it did indeed fix this bug.
          > > > >
          > > > > Andrew
          > > > >
          > > > > "Willie" <[email protected]> wrote:
          > > > > >Hi,
          > > > > >
          > > > > >Any update on this one? We are running into the exact same problem
          > and
          > > > > >it is
          > > > > >blocking us from moving into 6.1. The same code worked well in 6.0.
          > Is
          > > > > >this
          > > > > >a WL bug? When is the fix going to be available?
          > > > > >
          > > > > >Thanks!
          > > > > >Willie
          > > > > >
          > > > > >"Dror Last" <[email protected]> wrote in message
          > > > > >news:[email protected]...
          > > > > >> Hi
          > > > > >>
          > > > > >> attached is a web application called forward that demonstrate a
          > > > possible
          > > > > >> bug in weblogic 6.1 server.
          > > > > >>
          > > > > >> Description of the application
          > > > > >> ------------------------------------------
          > > > > >>
          > > > > >> index.html:
          > > > > >>
          > > > > >> <html>
          > > > > >> <head>
          > > > > >> <title>form</title>
          > > > > >> </head>
          > > > > >> <body>
          > > > > >> <form name="form" method="post" action="forwardServlet">
          > > > > >> <input type="hidden" name="nextPage" size="20"
          > > > > >> value="result.jsp">
          > > > > >> </form>
          > > > > >> <script language="javascript">
          > > > > >> document.forms["form"].submit();
          > > > > >> </script>
          > > > > >> </body>
          > > > > >> </html>
          > > > > >>
          > > > > >> the index.html of the application just cause the web browser to
          > send
          > > > > >a
          > > > > >> request to the ForwardServlet with a parameter
          nextPage=result.jsp
          > > > > >>
          > > > > >> ForwardServlet.java:
          > > > > >>
          > > > > >>
          > > > > >> import javax.servlet.http.*;
          > > > > >> import javax.servlet.*;
          > > > > >> import java.io.*;
          > > > > >>
          > > > > >> public class ForwardServlet extends HttpServlet {
          > > > > >>
          > > > > >> public void service(HttpServletRequest request,
          > > > > >> HttpServletResponse response) throws
          ServletException,
          > > > > >> IOException {
          > > > > >> RequestDispatcher disp =
          > > > > >> getServletContext().getRequestDispatcher("/" +
          > > > > >> request.getParameter("nextPage") +
          > "?result=kabooom");
          > > > > >> disp.forward(request, response);
          > > > > >> }
          > > > > >> }
          > > > > >>
          > > > > >> the servlet forwards the request to the nextPage(result.jsp)
          using
          > > > > >> RequestDispatcher.forward adding to the URI a parameter
          > result=kabooom;
          > > > > >>
          > > > > >>
          > > > > >> result.jsp:
          > > > > >>
          > > > > >> ****<P>
          > > > > >> <%
          > > > > >> String result = request.getParameter("result");
          > > > > >> out.println(result);
          > > > > >> %>
          > > > > >> <P>****
          > > > > >>
          > > > > >> the jsp just takes the "result" parameter from the request
          object
          > > > > >and
          > > > > >> prints it. However it gets a null instead of the String kaboom
          > > > > >>
          > > > > >>
          > > > > >> We use this method of adding parameters in many places in our
          > > > application
          > > > > >> and it should work according to the API:
          > > > > >> "For a RequestDispatcher obtained via getRequestDispatcher(),
          the
          > > > > >> ServletRequest object has its path elements and parameters
          adjusted
          > > > > >to
          > > > > >match
          > > > > >> the path of the target resource."
          > > > > >>
          > > > > >> Everything worked fine in WLS5.1
          > > > > >>
          > > > > >>
          > > > > >> P.S
          > > > > >>
          > > > > >> if ForwardServlet.java looks like:
          > > > > >>
          > > > > >> import javax.servlet.http.*;
          > > > > >> import javax.servlet.*;
          > > > > >> import java.io.*;
          > > > > >>
          > > > > >> public class ForwardServlet extends HttpServlet {
          > > > > >>
          > > > > >> public void service(HttpServletRequest request,
          > > > > >> HttpServletResponse response) throws
          ServletException,
          > > > > >> IOException {
          > > > > >> RequestDispatcher disp =
          > > > > >>
          > getServletContext().getRequestDispatcher("/result.jsp?result=kabooom");
          > > > > >> disp.forward(request, response);
          > > > > >> }
          > > > > >> }
          > > > > >>
          > > > > >> and not touching the request object itself the result.jsp will
          > display
          > > > > >> kaboom!!!!
          > > > > >>
          > > > > >>
          > > > > >> Dror Last
          > > > > >> Senior Software Engineer
          > > > > >> Unisfair Inc.
          > > > > >> 12 Yad Haruzim St. Tel Aviv 67778 Israel
          > > > > >> Tel: +972-3-5373738 Ext. 243
          > > > > >> Fax: +972-3-5373731
          > > > > >> GSM: +972-55-723710
          > > > > >> mailto:[email protected]
          > > > > >> http://www.unisfair.com/
          > > > > >>
          > > > > >>
          > > > > >>
          > > > > >>
          > > > > >>
          > > > > >
          > > > > >
          > > > >
          > >
          >
          >
          

Similar Messages

  • Return; after RequestDispatcher.forward();

    I notice that some examples using return; keyword right after the line with RequestDispatcher.forward(request, response);
    Can anyone pls explain when and why we do this?

    Thanks a lot BalusC. Can't believe I am so damn dumb not noticing that there were more codes after that block of codes....

  • Proper use of RequestDispatcher.forward()

    I have a servlet, and want to forward on to an error JSP page for
              exceptions. Is RequestDispatcher.forward() supposed to return to the
              source servlet when the target is finished?
              I am using a return to stop the source servlet when the target is
              finshed. Is this the correct behavior? Isn't this behavior very
              similar to to include(), or is the only difference that include() does
              not clear the source servlet's response buffer?
              TIA,
              Alex
              

    Alexander,
              The forward kindof has to return to the source servlet because that's
              where it's called from(unless it threw an exception). A servlet that
              performs a forward is meant to do preliminary processing of the request and
              allow another resource to generate the response. You are right in that it is
              basically an include that clears the buffer. If you want it to make a whole
              new request you should probably use a redirect.
              The weblogic docs help clarify things a bit(as well as the regular
              javadocs). http://www.weblogic.com/docs51/classdocs/API_servlet.html#129331
              Hope this helped.
              -jeremy
              Alexander Kowalyshyn <[email protected]> wrote in message
              news:[email protected]..
              > I have a servlet, and want to forward on to an error JSP page for
              > exceptions. Is RequestDispatcher.forward() supposed to return to the
              > source servlet when the target is finished?
              >
              > I am using a return to stop the source servlet when the target is
              > finshed. Is this the correct behavior? Isn't this behavior very
              > similar to to include(), or is the only difference that include() does
              > not clear the source servlet's response buffer?
              >
              > TIA,
              >
              > Alex
              >
              

  • Port Forward Bug?

    I have the latest Apple Airport Extreme (AC router) and everyhting has been working flawlessly.  However today, certain services that were forwarded and working, have stopped.  Specifically the L2TP ports (500, 1701 and 4500) and the remote admin port (311).  Others like 80 and 443 are working just fine.  Using an outside service to check if the ports are open or not, it tells me the problem ports are closed, however they are configured properly in the airport extreme.
    Nothing has changed.  I'm completely lost.

    From other reports there are indeed port forwarding bugs.. the major one is port 21 FTP which you are not using but the bug is very serious.
    https://discussions.apple.com/message/22927625#22927625
    The last post in this thread by.. SBeattie2
    I think will condemn you to replacement of the AC by a router that actually conforms to standards.

  • Differences between (response.sendRedirect and Requestdispatcher.forward)

    Hi All,
    I have 3 queries
    *1> I wanted to know the "Differences" between*
    response.sendRedirect and Requestdispatcher.forward
    *2> when do we Opt for response.sendRedirect?*
    *3> when do we Opt for Requestdispatcher.forward?*
    Thanks,
    Deepak AL

    The fundamental difference is that sendRedirect is a client based direction, while forward is a server based one.
    SendRedirect forces the client to make a new request. In effect you are telling the client browser "What you are looking for is over there"
    RequestDispatcher forward, is purely an internal server transition. The client knows nothing about the forward happening.
    Example
    Lets say you request the page www.myserver.com/myPage.jsp
    Example A: Redirect
    We send a redirect to www.myserver.com/thatPageOverThere.jsp
    The browser receives this message, and its address url changes to www.myserver.com/thatPageOverThere.jsp, and it sends a new request over there.
    Note that it is a completely new request, so any parameters that were sent with the old request are irrelevant. If you want to send them again you have to put them into the sendRedirect url.
    You can also send a redirect to www.myOtherServer.com/thatPageOnACompletelyDifferentServer.jsp
    Example B: Forward to thatPageOverThere.jsp
    We obtain a request dispatcher to "thatPageOverThere.jsp" and forward to that resource.
    The server instead of running myPage.jsp now executes and returns thatPageOverThere.jsp
    The client browser knows nothing of this. As far as it knows it asked for myPage.jsp, and it is getting that response back.
    So if you forward to something like "my/page/inASubFolder.jsp" you have to be very careful with relative links on the page.
    The browser requested myPage.jsp, so it will resolve relative links from that Url.
    When to use one or the other?
    Redirect would need to be used when the resource is on another server.
    Another common usage is the "Post-Redirect-Get" pattern. (you might want to look that up)
    Hope this helps you understand a little.
    cheers,
    evnafets

  • How to use RequestDispatcher.forward method  in a portlet

    I have a servlet (HelloServlet2) that acts as the controller. This is a very simplified example. This servlet calls the dispatcher.foward(req, res) method to foward to a JSP page for displaying. At this point I get a FileNotFoundException. The HelloServlet2 is in the standard location WEB-INF/classes/com/a2i/industrial/servlet/HelloServlet2.java.
    How come it's looking in Industrial/servlet/HelloServlet2 instead of Industrial/WEB-INF/classes/..? If I access the servlet by http://host:port/Industrial/HelloServlet2, it works fine. I have another portlet (servlet) that doesn't call the forward method and it works fine too. Thanks for your help.
    Here is the web.xml:
    <servlet>
    <servlet-name>HelloServlet2</servlet-name>
    <display-name>HelloServlet2</display-name>
    <servlet-class>com.a2i.industrial.servlet.HelloServlet2</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>HelloServlet2</servlet-name>
    <url-pattern>/HelloServlet2/*</url-pattern>
    </servlet-mapping>
    Here is the calling code from HelloServlet2:
    public void doGet(HttpServletRequest req, HttpServletResponse res)
    throws ServletException, IOException
    RequestDispatcher dispatcher= getServletContext().getRequestDispatcher("/hello.jsp");
    dispatcher.forward(req, res);
    Here is the portlet definition:
    <portlet class="oracle.portal.provider.v2.DefaultPortletDefinition">
    <id>2</id>
    <name>HelloServlet2</name>
    <title>Hello Servlet2</title>
    <shortTitle>Hello Servlet2</shortTitle>
    <description>This is the "hello world" sample implemented using Java Servlets and the extensible renderer architecture.</description>
    <timeout>10000</timeout>
    <timeoutMessage>Hello Servlet timed out</timeoutMessage>
    <acceptContentType>text/html</acceptContentType>
    <renderer class="oracle.portal.provider.v2.render.RenderManager">
    <contentType>text/html</contentType>
    <autoRedirect>true</autoRedirect>
    <showPage>/servlet/HelloServlet2</showPage>
    </renderer>
    </portlet>
    Here is the stack trace:
    7/15/03 10:43 AM industrial: JspServlet: unable to dispatch to requested page: java.io.FileNotFoundException: C:\ora9iasp\j2ee\OC4J_Portal\applications\_industrial\industrial\servlet\HelloServlet2 (The system cannot find the path specified)
         at java.io.FileInputStream.open(Native Method)
         at java.io.FileInputStream.<init>(FileInputStream.java:64)
         at oracle.jsp.provider.JspFilesystemResource.fromStream(JspFilesystemResource.java:153)
         at oracle.jsp.provider.JspFilesystemResource.fromReader(JspFilesystemResource.java:169)
         at oracle.jsp.runtimev2.JspPageCompiler.fromReader(JspPageCompiler.java:345)
         at oracle.jsp.runtimev2.JspPageCompiler.attemptCompilePage(JspPageCompiler.java:250)
         at oracle.jsp.runtimev2.JspPageCompiler.compilePage(JspPageCompiler.java:171)
         at oracle.jsp.runtimev2.JspPageInfo.compileAndLoad(JspPageInfo.java:338)
         at oracle.jsp.runtimev2.JspPageTable.compileAndServe(JspPageTable.java:481)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:255)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:407)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:330)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:59)
         at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:283)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:523)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:269)
         at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:219)
         at com.a2i.industrial.servlet.HelloServlet2.doGet(HelloServlet2.java:21)
         at com.a2i.industrial.servlet.HelloServlet2.doPost(HelloServlet2.java:14)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:283)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:59)
         at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:283)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:523)
         at com.evermind.server.http.ServletRequestDispatcher.include(ServletRequestDispatcher.java:108)
         at oracle.portal.provider.v2.render.http.ResourceRenderer.renderBody(Unknown Source)
         at oracle.portal.provider.v2.render.RenderManager.render(Unknown Source)
         at oracle.portal.provider.v2.DefaultPortletInstance.render(Unknown Source)
         at oracle.webdb.provider.v2.adapter.soapV1.ProviderAdapter.showPortlet(Unknown Source)
         at oracle.webdb.provider.v2.adapter.soapV1.ProviderAdapter.handleHttp(Unknown Source)
         at java.lang.reflect.Method.invoke(Native Method)
         at oracle.webdb.provider.v2.adapter.SOAPServlet.doHTTPCall(Unknown Source)
         at oracle.webdb.provider.v2.adapter.SOAPServlet.service(Unknown Source)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:336)
         at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:59)
         at oracle.security.jazn.oc4j.JAZNFilter.doFilter(JAZNFilter.java:283)
         at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:523)
         at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:269)
         at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:735)
         at com.evermind.server.http.AJPRequestHandler.run(AJPRequestHandler.java:151)
         at com.evermind.util.ThreadPoolThread.run(ThreadPoolThread.java:64)
    7/15/03 10:43 AM industrial: ERROR: ResourceRenderer.renderBody - Resource "/servlet/HelloServlet2" returned HTTP Status: 404. Error message: OracleJSP:
    java.io.FileNotFoundException: C:\ora9iasp\j2ee\OC4J_Portal\applications\_industrial\industrial\servlet\HelloServlet2 (The system cannot find the path specified). Content returned follows....

    Thanks for you help David. I changed my code from getServletContext().getRequestDispatcher(jspPage).forward(req, res) to getServletContext().getNamedDispatcher(jspPage).forward(req, res). It worked but I run into the same problem with jsp:include.
    I am using the July 2003 of the PDK. I followed the direction for installing version 2 but I did not redeploy with the new jpdk.ear since one was already deployed. After redeploying with the new jpdk.ear, it fixed the jsp:include problem I was having. The problem with using getServletContext().getRequestDispatcher(jspPage).forward(req, res) STILL exist. I am not sure what the deal is.
    Oh, I also tried the code below and it doesn't work.
    path = req.getContextPath() + jspPage
    getServletContext().getRequestDispatcher(path).forward(req, res)
    In any case, using getNamedDispatcher() is working fine. I am still curious about getRequestDispatcher() though.

  • Error While using RequestDispatcher.forward

    Hi All,
    I am getting an error while i am forwarding a request from a controller servlet to a JSP in WAS 3.5.
    i am using the following code:
    String url = "../gede/globalservices/SCSLogin.jsp";
    RequestDispatcher rd = getServletConfig().getServletContext().getRequestDispatcher(url);
    rd.forward(request, response);
    The error i get is :
    Error 404
    An error has occured while processing request:http://teamsite-cwc-review.indsys.ge.com/cwc/servlet/com.geindsys.gede.globalservices.SCSControllerServlet
    Message: [JSP 1.0 Processor] reported an error
    i was able to get the same while using response.SendRedirect(url);
    Please help..
    Thanks in Advance..
    Regards,
    Ravi.

    Looks like your JSP is throwing an exception. Check the logs in your server to find the details about it. (Was there an XML question here? I couldn't see one.)

  • Error While using RequestDispatcher.forward --URGENT!!!

    Hi All,
    I am getting an error while i am forwarding a request from a controller servlet to a JSP in WAS 3.5.
    i am using the following code:
    String url = "../gede/globalservices/SCSLogin.jsp";
    RequestDispatcher rd = getServletConfig().getServletContext().getRequestDispatcher(url);
    rd.forward(request, response);
    The error i get is :
    Error 404
    An error has occured while processing request:http://teamsite-cwc-review.indsys.ge.com/cwc/servlet/com.geindsys.gede.globalservices.SCSControllerServlet
    Message: [JSP 1.0 Processor] reported an error
    i was able to get the same while using response.SendRedirect(url);
    Please help..
    Thanks in Advance..
    Regards,
    Ravi.

    I think the problem is in the ".." part of your url.
    If you have a webapp named cwc in the webapps/cwc directory and in this webapp in there is a file SCSLogin.jsp under webapps/cwc/gede/globalservices you should use a URL:
    String url = "/gede/globalservices/SCSLogin.jsp";

  • Mail forwarding bug?

    In one of my Apple Mail POP accounts, when I forward a message, the message goes through to the destination just fine. But the little arrow that should appear to the left of the message, indicting that it has been forwarded, does not appear. (And, yes, the forwarded message is in my sent box.) This started happening right after I upgraded to Snow Leopard.
    And, investigating further, when I click on one of the arrows of earlier forwarded messages, rather than open the forwarded message in a new window, I get the message:
    "Mail was unable to find your reply to the message “Subscription Order: 5 Years”. You may have deleted the message."
    This is weird, since it was a forwarded message (not a reply), and , of course, these message are in my sent box.
    I don't know if theses bugs are related, and the second bug could have been happening earlier nd I didn't know it. But the new bug, the arrow not appearing, started with my Snow Leopard upgrade.
    And my other mail accounts (all my accounts are POP) work fine.
    Unfortunately the buggy account is the one that I need to use to forward messages to my business partner, and it really helps to see which ones have already been forwarded -- but I can no longer quickly see that.
    Can anyone suggest anything to fix this? I've already run the Disk Utility permissions repair ...
    Thanks!
    John

    johnsky wrote:
    Thanks for your reply. Unfortunately, I have a lot of mailboxes, most of which are working fine, in several domains, so before I do this ...
    1) If I make a backup copy of the old prefs file before I delete it, and I run into a problem, will I simply be able to copy the old prefs file back to where it was and have my setup the way it was?
    yes. the mail preference file only contains mail preferences. the actual mailboxes live in home directory/library/mail. they will not be touched by this process.
    2) When I create new preferences, will I still see the little arrows/links next to old messages (in the mailboxes that are working correctly now) indicating that the message was replied to or forwarded? It would be a drag to lose those.
    yes.
    3) As an alternative to creating new prefs for all my mailboxes, what do you think about this idea... Might it work if I create a new mailbox (with new prefs, I assume) for each of my flawed accounts and simply drag the old messages into the new milbox? And then delete the old one? Would this screw something up?
    you can't do that. there is just one mail preference file for everything.
    Thanks!
    John

  • RequestDispatcher.forward on OAS 4.0.8.1 for Servlet Communication

    We are unable to pass request information from a servlet to another servlet or a JSP on OAS 4.0.8.1 whereas we have been able to achieve this
    successfully in JDK using the same code.
    Since Servlet Chaining is not supported in the JServlet of OAS, use the forward
    method in the RequestDispatcher object instead.
    RequestDispatcher rd;
    rd =getServletConfig().getServletContext().getRequestDispatcher(/testme1/USe
    rvl
    et);
    rd.forward(request,response);
    It didn't do anything with the forward method and nothing was logged in the log file. Anyone out there, please send help ASAP. Thanks.
    null

    After I fixed some of the things I broke while searching for the wrksf failure, the PL/SQL Cartridge now works for me too. And, after failing to get the DB Browser to work by loading it into the SCOTT schema, I got it to work by loading it into SYS. (SCOTT can't see the DBA_* views so loading the DB Browser into the database failed.) I haven't tried any Java Servlets yet, but that's next on my list.
    If you want to try my wrksf workaround, rather than using Christoph's, here's how you can do it.
    1. Backup liborb.so in the $ORACLE_HOME/orb/4.0/lib directory, just in case something goes wrong.
    2. Using a hex editor, such as emacs hexl-find-file or ghex, to edit liborb.so, find the string "/proc/stat".
    3. Change the directory, "/proc" to something like "/pfoo" and write the shared library file back to liborb.so. You now have the required modified liborb.so.
    4. Make the /pfoo directory and cp /proc/stat /pfoo.
    5. Edit /pfoo/stat and duplicate the first line, which should be the cpu line. This will let the metrics parser handle it. Make sure that /pfoo/stat has read access.
    Of course, the values that the metrics code gets are now bogus, but that does not seem to be a fatal problem.
    Hopefully somebody from Oracle is reading this and the real fix will be in the mail soon.

  • RequestDispatcher forwarding to a blank page

    RequestDispatcher is forwarding to a blank page The code is like this but I a always getting a blank page.This is all written in a JSP page but still I can not access the imlicit objects like request and response I need to declare them explicitly.I do not know what is going wrong this is first time I am writing everything in JSP
    public boolean deviceType(){
              String flash = "flash";
              String img = "img";
              HttpServletRequest request = null;
              HttpServletResponse response = null;
              RequestDispatcher rd = request.getRequestDispatcher("");
            /*try {
                   rd.forward(request, response);
              } catch (Exception e) {
                   e.printStackTrace();
              if(contentType.equals(flash)){
                        if(isFlash()){
                                  rd = request.getRequestDispatcher("/flashOK.jsp");
                                  try {
                                       rd.forward(request, response);
                                  } catch (ServletException e) {
                                       e.printStackTrace();
                                  } catch (IOException e) {
                                       e.printStackTrace();
                            }else{
                             rd = request.getRequestDispatcher("/flashNG.jsp");
                                 try {
                                       rd.forward(request, response);
                                  } catch (ServletException e) {
                                       e.printStackTrace();
                                  } catch (IOException e) {
                                       e.printStackTrace();
              }else if(contentType.equals(img)){
                        if(isImg()){
                                     rd = request.getRequestDispatcher("/imgOK.jsp");
                            try {
                                  rd.forward(request, response);
                             } catch (ServletException e) {
                                  e.printStackTrace();
                             } catch (IOException e) {
                                  e.printStackTrace();
                        }else{
                             rd = request.getRequestDispatcher("/imgNG.jsp");
                            try {
                                  rd.forward(request, response);
                             } catch (ServletException e) {
                                  e.printStackTrace();
                             } catch (IOException e) {
                                  e.printStackTrace();
              }else{
                   rd = request.getRequestDispatcher("/notSupported.jsp");
                       try {
                             rd.forward(request, response);
                        } catch (ServletException e) {
                             e.printStackTrace();
                        } catch (IOException e) {
                             e.printStackTrace();
                        return false;
              return false;
         }

    If you want to use the implicit variables in your method, pass them in as parameters:
    ie
    public boolean deviceType(HttpServletRequest request, HttpServletResponse response...){However you have quite a bit of code in there.
    Personally I would not bother with catching the exceptions from the request dispatcher for each call.
    1 - there is nothing you can do if it fails
    2 - the page will print an error message itself if you let it fall through.
    This is one of those cases where exception handling code just makes it over complex, and hides your true intentions.
    What you are trying to do looks fairly simple. Is there a reason it is in its own function?
    Cheers,
    evnafets

  • New Message or Forwarding  Bug??

    This issue has happened intermittently... when i wish to forward a email message i usually type the first letter and it will give me a list based upon my address book entries. This appears to have a bug that i will get a list of email contacts that are NOT in my address book. As a matter of fact none of my address book email contacts pops up. This also is the case when creating a new email. This is weird and i cant seem to get my head around this one to fix it.

    First of all have you checked the Previous Recipients list -- Window, choose Previous Recipients. If you are satisfied that all contacts you care about are in the primary AB, then you can remove all those in the Previous Recipients list.
    I have not seen the difference in this behavior with Forward vs New Message, btw.
    Ernie

  • WRT160NL Port Forwarding Bug?

    I have 2 NAS drives with FTP servers built in. I want to set my WRT160NL to forward single ports to these servers.
    In the single port forwarding page, I set:
    External port 100, Internal port 21, Both, IP: 192.168.1.10
    External port 200, Internal port 21, Both, IP: 192.168.1.20
    This should be fine since there are 2 devices, each with their own IP address. But, I get an error message when I try and save "The port range already exists". If i reconfigure one of the devices to use a different internal port then I can save, but I should not have to.
    Is this a known bug?

    Thanks, I know there are workarounds (I mentioned I could reconfigure one of the NAS servers in my post). That is not what I am after.
    As it turns out, if I use the preset "FTP" then I can also use Port 21, so I can set 2 devices, but this is still not the correct solution. 
    After more research, this appears to be a problem with many other models, why doesn't Cisco/Linksys fix this issue. Seems easy enough to me. This could even be just an issue with the javascript and there is no technical reason why it was blocked.
    Message Edited by do on 10-07-2009 01:04 PM
    Message Edited by do on 10-07-2009 01:05 PM

  • Installing Safari 3 Beta casues Reply/Forward Bug in Mail

    After installing Safari 3 Beta any Reply/Forward e-mail command opens new e-mail without original mail text content uncluded.
    Attached files are forwarded, although.
    Could you confirm?
    PB G4 1.5GHz   Mac OS X (10.4.9)   1GB Samsung 160GB

    What type of account(s) are you using -- POP, IMAP or .mac? I would like you to create a New User Account on your Mac, and as that New User set up at least one email account, and test for this behavior. If POP, do you leave the messages on the server for a while after downloading -- this would provide that you have messages with which to test, as the New User's Mail would again download those message that remain on the server. Also, if using POP, I would want you to quickly check to not allow the New User email account to remove any message it downloads, before you later can download them into your normal user account.
    To create a New User Account, see:
    http://docs.info.apple.com/article.html?path=Mac/10.4/en/mh168.html
    Also, open a message you have received and tried to Forward, click on View in the Menubar, place the cursor on Message and choose Raw Source. See of the text that has not come into the Compose window is ordinary looking, or itself in some sort of attachment?
    Ernie

  • Can RequestDispatcher.forward() forward to a plain html file

    Hi,
              I'm using the 4.5.1 eval weblogic server to service my jsps and servlets.
              I'm using IIS 4.0 to serve the web pages. I've set up IIS4.0 to send all
              *.jsp, *.jhtml, and *.servlet files to weblogic. I'm trying to forward the
              request from a servlet to an plain old html file. The html file is located
              in c:\inetpub\wwwroot. I have my weblogic.httpd.documentRoot set to
              c:\inetpub\wwwroot. I can't find a way to make this work. I've tried
              various combinations include
              equestDispatcher.forward( "/register2.html",req,resp) ....
              forward( "/file/register2.html",req, resp ) ... Any suggestions? BTW
              everything works fine if register2.html is renamed to register2.jsp and kept
              in the same directory.
              Thanks,
              John
              

    Sorry (and thankyou very much for your response).... but, I'm not confident that I understand fully what you mean....
    Since, what I want to do is write the output generated from my servlet to a specific frame in the frameset.
    How does
    "<a href="http://myDomain.com/servlet/MyServlet" target="frameName">My Servlet</a>"
    help me to do that?
    -- Are you assuming that I am invoking the servlet from somewhere in the frameset to begin with?
    Thanks again for your input!

Maybe you are looking for

  • Has anyone seen this BUG with Time Warp and Dissolve?

    I'm doing some real basic slow-mo clips, transitioning with various dissolve wipes. I've come across a problem that is extreemly frustrating! I'm wondering if anyone has insight on a fix or if Adobe does service packs or fixes that I might be able to

  • Why is the zoom button grayed out when I scan

    Operating system: Windows 7 Software: Adobe Elements CS2 Scanner Cannon 9000f When I scan a single image the zoom button is grayed out, but when I scan multiple images it is activated.  How do I activate it for a single scan.  I have selected the ite

  • Alv report  filter a filed

    hi, please give help on filtering on particular field in alv gird display.     i want to filter on MARA-MRTAR ( Matrial type) .give me code for that. plz i need urgently.

  • Mail account name error

    I had some problems with an email account in Mail.app so i deleted the account. When i wan't to add a new account and give it the same name the account i deleted had it gives me the message; Error You already have an account named: "xxx". I tried del

  • Field status - Commitment Item

    We need to make the Commitment Item field in the GL entry screen in DISPLAY mode. The field status offers only Suppress, required and Optional. How do we configure the same??