Redirect to a servlet when using a proxy

Hello,
How can I redirect to a servlet from a jsp without hardcoding any directory/parts of the url?
I am using tomcat v.3.2.1.
The webapp is behind a proxy server and that address can change so when the real url to a jsp called myjsp.jsp would be something like "www.host.com/webapp/myjsp.jsp", it is now proxied to something like "www.otherhost.com/somenicedir/otherdir/webapp/myjsp.jsp" now the proxy part ("www.otherhost.com/somenicedir/otherdir") can change and I need to know how to redirect from a jsp to a servlet without hardcoding the proxy part.
If I redirect from a jsp to a jsp I can just do it with sendRedirect("otherjsp.jsp") since it is in the same folder. But for a servlet, since it is in a different folder the redirect would be something like sendRedirect("/servlet/myServlet") but when I send that with a proxy, it goes to "www.otherhost.com/webapp/myjsp.jsp" and then it gives you error page not found since it is missing the dirs in between.
So how do I make a clean redirect from a jsp to a servlet inside the same webapp without it getting redirected to some wrong address if its proxied?
-teka

Thanks for the tip, it seems to give the address of the real server though, not the proxied one.
I was wrong about the redirection though, it was from a servlet I need to redirect to a jsp not the other way around.
Seems like redirecting to /webapp/servlet/servletname works but now i need a way to redirect to a jsp from a servlet with a relative path or some other way to pass the beginning of the URL which can change.. Any ideas anyone?
-teka

Similar Messages

  • CSA control of IE communication when using a proxy ?

    Has anyone tried to do a network access control rule for IE communication when using a Proxy server in IE ? How would CSA know what sites are visited by ip if all comms are to the proxy server ?

    I found that after Firefox v29, a LOT of my settings and<BR>
    add-ons were changed / reset. Try this;
    '''''[https://support.mozilla.org/en-US/kb/troubleshoot-firefox-issues-using-safe-mode Start Firefox in Safe Mode]'''''
    <BR>While you are in safe mode;<BR>
    '''''Firefox Options > Advanced > General'''''.<BR>
    Look for and turn off '''Use Hardware Acceleration'''.<BR>
    Then check ALL of your settings. Browser and add-ons. Then restart.

  • When using a proxy server at work, Deezer page does not load normally?

    When using a proxy server at work, Deezer page does not load normally, but when I go home and use connection without proxy, everything is fine.
    It loads, and some features on the website work, but the look is not the same. Over the proxy it shows just text on the left side of the screen and I can't choose some of the options.
    When I go home and use my home connection without proxy, there are no problems, everything is OK.
    Could you please solve this?

    I found that after Firefox v29, a LOT of my settings and<BR>
    add-ons were changed / reset. Try this;
    '''''[https://support.mozilla.org/en-US/kb/troubleshoot-firefox-issues-using-safe-mode Start Firefox in Safe Mode]'''''
    <BR>While you are in safe mode;<BR>
    '''''Firefox Options > Advanced > General'''''.<BR>
    Look for and turn off '''Use Hardware Acceleration'''.<BR>
    Then check ALL of your settings. Browser and add-ons. Then restart.

  • Firefox leaking DNS queries when using a proxy

    When configuring firefox to use a PAC file for proxy configuration, or when using the "system proxy settings" option, firefox queries the internal DNS server for every request, instead of using the proxy. I've see other "bugs" people have mentioned when using a socks proxy that sound similar, but this happens with just a regular proxy in my example (over port 8080)

    Hi,
    Which edition of windows server you are running?
    You can point your clients to proxy server via GPO or GPP:
    For previous version:
    userconfig->policy->
    windows
    settings->
    internet
    explore
    maintence
    And the later version:
    user
    config->preference->control panel settings->internet settings->new
    Appendix B: Replacements for Internet Explorer Maintenance
    http://technet.microsoft.com/en-us/library/jj890998.aspx
    Hope this helps.

  • Browser settings of safari when using college proxy

    Background:I'm using macbook pro (mid 2012) and have recently updated it to OSX 10.9.
    I'm using college proxy to run internet and i'm unable to connect my safari to net while others like firefox and chrome are running well.
    I find this problem when using the college net only. When I use USB Data card to connect to net my safari is running well.
    Before the software update I could atleast connect my app store but now I'm unable to do it.
    Please help me out.

    You would have to check with the network administrator to find out the correct proxy settings.

  • No tables listed when using a proxy connection in SQL Developer

    Hello, I'm trying to use a connection in SQL developer that uses the proxy connection to connect to another users tables. In the SQL worksheet area I can access the other users tables with no problems. And using SELECT COUNT(*) FROM USER_TABLES i get the count of the number to tables. But on the tables view on the left hand side of SQL developer no tables are listed. So the question is why do I not see any tables under the tables view? Is this a bug or is it working by design? Thanks

    To access other user's objects, use the Other Users node...
    K.

  • Why do pages load very slowly when using a proxy in Win 7?

    Whenever I try to use a proxy server,it will work okay a couple of times. Then after that pages will start loading very slowly,so that I find that I have to uninstall the proxy program.I am using Win7 Ultimate,a netgear router, and high speed internet "10Mbps"..I have tried different proxy hiders and they all do the same thing.Can anyone help?????????????

    Exceedingly slow download speeds on...: Apple Support Communities

  • How can I disable DNS queries in Firefox (when using a proxy) ?

    I am behind a "Chinese wall" and use an HTTP proxy to tunnel and encrypt my data traffic.
    Unfortunately, Firefox still sends DNS queries for the websites, that I visit and reveals more information than I want.
    Is there a way to disable DNS, when I use an HTTP/S proxy ?
    My current workaround is to set a firewall rule for outbound DNS traffic of Firefox. But not all users are able to configure their firewall.

    That is done via an onbeforeunload or onunload event that displays a JavaScript alert.
    *https://developer.mozilla.org/en/DOM/window.onbeforeunload
    *https://developer.mozilla.org/en/DOM/window.onunload
    You can try to search for a Greasemonkey script to reset and block such events.
    *http://www.greasespot.net/ - Greasemonkey
    *http://wiki.greasespot.net/Main_Page - GreaseSpot

  • Error in  pdk url services when using a proxy server

    Hi All,
    i created a pdk url services portlet, which connects to a google site. i got a sucessful provider test page..when i tried to add it as a portlet it gives me the following error ,
    Portlet Information could not be obtained. (WWC-44334)
    An unexpected error occurred: ORA-29532: Java call terminated by uncaught Java exception: HTTPClient.AuthSchemeNotImplException: NTLM (WWC-43000)
    An unexpected error occurred: HTTPClient.AuthSchemeNotImplException: NTLM
    at HTTPClient.DefaultAuthHandler.getAuthorization(DefaultAuthHandler.java:136)
    at HTTPClient.AuthorizationInfo.queryAuthHandler(AuthorizationInfo.java:330)
    at HTTPClient.AuthorizationModule.setAuthHeaders(AuthorizationModule.java:454)
    at HTTPClient.AuthorizationModule.responsePhase2Handler(AuthorizationModule.java:287)
    at HTTPClient.HTTPResponse.handleResponse(HTTPResponse.java:635)
    at HTTPClient.HTTPResponse.getInputStream(HTTPResponse.java:515)
    at oracle.webdb.provider.web.HttpProviderDispatcher.dispatch(HttpProviderDispatcher.java:809)
    what could be the reason for this error. can anyone help me plzz..its urgent
    Regds
    Kiran
    at oracle.webdb.provider.web.HttpProviderDispatcher.getPortlet(HttpProviderDispatcher.java:463)
    (WWC-43000)

    1. The version of my pdk is 3.0.9.0.5
    2. provider.xml
    <?xml version = '1.0' encoding = 'UTF-8'?>
    <?providerDefinition version="2.0"?>
    <provider class="oracle.portal.provider.v1.http.URLProvider">
    <session>true</session>
    <proxyInfo class="oracle.portal.provider.v1.http.ProxyInformation">
    <httpProxyHost>proxy</httpProxyHost>
    <httpProxyPort>80</httpProxyPort>
    <proxyUser>username</proxyUser>
    <proxyPassword>password</proxyPassword>
    </proxyInfo>
    <portlet class="oracle.portal.provider.v1.http.URLPortlet">
    <id>1</id>
    <name>Google.com Portlet</name>
    <title>Google.com Portlet</title>
    <description>This portlet is to test PDK-URL Services using Google</description>
    <timeout>100</timeout>
    <timeoutMessage>Google Portlet timed out</timeoutMessage>
    <showEdit>false</showEdit>
    <showEditDefault>false</showEditDefault>
    <showPreview>false</showPreview>
    <showDetails>false</showDetails>
    <hasHelp>false</hasHelp>
    <hasAbout>false</hasAbout>
    <acceptContentType>text/html</acceptContentType>
    <registrationPortlet>false</registrationPortlet>
    <accessControl>public</accessControl>
    <renderer class="oracle.portal.provider.v1.RenderManager">
    <showPage class="oracle.portal.provider.v1.http.URLRenderer">
    <contentType>text/html</contentType>
    <pageExpires>60</pageExpires>
    <pageUrl>http://www.google.com</pageUrl>
    <filter class="oracle.portal.provider.v1.http.HtmlFilter">
    <headerTrimTag>&lt;center</headerTrimTag>
    <footerTrimTag>/center></footerTrimTag>
    <convertTarget>true</convertTarget>
    </filter>
    </showPage>
    </renderer>
    <securityManager class="oracle.portal.provider.v1.http.URLSecurityManager">
    <authorizType>public</authorizType>
    </securityManager>
    </portlet>
    </provider>
    Regds
    Kiran

  • PI is slow when using Sender Proxy.

    Hi,
    We configured Proxy to PI to JDBC, interface is working fine when getiing around 10,000 records. We are facing problems when there are 40000 to 50000 records. Cant PI handle these many records.
    PI is going very slow and and nearly taking 2-3 hrs for processing records to target system.
    What was the reason and please let me know how to achieve this process.
    Thnaking you,
    Hari

    Hi Hari,
    First of all using proxy the performance will be good than using adapters. So basically the issue is not with the proxies. It may be the peoblem with the configuration and the process which you are following.
    If you are getting data from multiple interface which means that multiple applications. If you are inserting all the inerfaces data into same table better you can use stored procedure instead of standard functionality . If you are using this stored procedure the execution will be happen at database side. In this case it will not take much time to process the records to database.
    Regards,
    Raju

  • Response message error in queue when using ABAP proxy

    I am using an abap proxy for the first time, and some of the response messages are getting stuck in the sender's (R/3) inbound queue.  To resolve them, I have to either reset the status or execute the LUW.  Sometimes, this doesn't even work. 
    Here is my "asynchronous" scenario:
    R/3 -> <proxy> -> PI -> <file adapter> -> File
    The R/3 system that I'm using has not used PI before, so I'm thinking something is missing from the set-up on the R/3 side.  On the errors I finally do get to process, I get the following error in the SXMB_MONI on the sender (R/3) side (the PI SXMB_MONI shows successful).  Can someone help me understand what a response message is and how it is different from an acknowledgement?  Also, help me to understand what could be causing the response messages to get stuck in the R/3 queue.
    <?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
    - <!--  Call Integration Server -->
       - <SAP:ErrorHeader xmlns:SAP="http://sap.com/exchange/MessageFormat">
        <SAP:Context />
        <SAP:Code p1="MessageId"
                          p2="4962B2EDB60A003BE1008000A2844D1A"
                          p3="00000000000000000000000000000000"     
                          p4="">PROTOCOL.WRONG_HEADER_IN_RESPONSE</SAP:Code>
        <SAP:Text language="EN">Response message header contains the value 00000000000000000000000000000000 in element MessageId instead of the expected value 4962B2EDB60A003BE1008000A2844D1A</SAP:Text>
      </SAP:ErrorHeader>

    Ultimate testing tool for services is soapUI (Freeware)
    http://www.soapui.org/
    If you can invoke your service from soapUI and you receive a response, then PeopleSoft is working fine and the request handling in the calling system is incorrect.
    Try downloading soapUI and try invoking your service (not that a fan of SendMaster).
    Hakan

  • Problems with ESS when using reverse proxy

    Hello, we are using an F5 Local Traffic Manager to load balance traffic to a SAP ERP portal.  Everything works just fine, until you click on the Employee Self Service tab.  By default, it should just take you into the employee self service page, but instead it give's you another log in page.  If you try and log in, the server will not let you, because it thinks you are already logged in.  I believe this might be a redirect problem on the ESS side, but wanted to get other opinions first, and work form there to a resolution. 
    Thanks,
    -GW

    Hi Timo,
    I'm also facing the exact problem, did you find a fix for this? If yes could you please share that with me.
    Regards
    Vaib

  • Crashes when using corporate proxy and accessing MobileMe mail. Proxy seems to be doing SSL interception

    I authenticate to the corporate proxy and then get the following detail about untrusted SSL connected:
    "The certificate is not trusted because no issuer chain was provided."
    I add an exception so I can continue and then get the same message again except I don't have the option to continue. I can view the cert or cancel. When I choose cancel FF crashes.
    Crash signature: nsTArray<nsHttpHeaderArray::nsEntry, nsTArrayDefaultAllocator>::IndexOf<nsHttpAtom, nsHttpHeaderArray::nsEntry::MatchHeader>(nsHttpAtom const&, unsigned int, nsHttpHeaderArray::nsEntry::MatchHeader const&) | nsHttpHeaderArray::GetHeader(nsHttpAtom, nsA...

    .me is imap and I doubt it can be set to pop access.  You can go to the iCloud.com website and forward your .me account to a gmail address.

  • Can't redirect to the servlet when with submit botton?

    What have I put in the form action="?" field? I puted the name of the servlet like in the web.xml file so action"/servlet1", but when I lick on the button nothing happend. Is there an error of the name of the servlet in the "action" field?
    This is my web.xml file:
    <?xml version = '1.0' encoding = 'windows-1252'?>
    <!DOCTYPE web-app PUBLIC "-//Sun Microsystems, Inc.//DTD Web Application 2.3//EN" "http://java.sun.com/dtd/web-app_2_3.dtd">
    <web-app>
    <description>Empty web.xml file for Web Application</description>
    <servlet>
    <servlet-name>Servlet1</servlet-name>
    <servlet-class>servlet.Servlet1</servlet-class>
    </servlet>
    <servlet-mapping>
    <servlet-name>Servlet1</servlet-name>
    <url-pattern>/servlet1</url-pattern>
    </servlet-mapping>
    <session-config>
    <session-timeout>35</session-timeout>
    </session-config>
    <mime-mapping>
    <extension>html</extension>
    <mime-type>text/html</mime-type>
    </mime-mapping>
    <mime-mapping>
    <extension>txt</extension>
    <mime-type>text/plain</mime-type>
    </mime-mapping>
    </web-app>
    Thanks in advance.

    This is my from:
    <form action="/servlet/servlet1" method="post" id="search" style="font: bold 80% Arial,sans-serif; color: #334d55;" />
    <input type="hidden" name="pagina" value="1" />
         user<input name="username" type="text" size="10" style="font-size: 12px;"/> 
    password<input name="password" type="password" size="10" style="font-size: 12px;"/>
         <input name="login" type="submit" value="Login" style="font-size: 12px; font-family: Arial,sans-serif;"/>
    </form>
    Something wrong?
    Thanks.

  • Can not redirect to other page when using adfc-config.xml in standalone WL

    Hi all,
    I created a very simple fusion app, only have two jspx pages(view1 view2). I drag these two pages to adfc-config file and created a control flow(adfcView2) between these two pages.
    +<?xml version="1.0" encoding="UTF-8" ?>+
    +<adfc-config xmlns="http://xmlns.oracle.com/adf/controller" version="1.2">+
    +<view id="view1">+
    +<page>/view1.jspx</page>+
    +</view>+
    +<view id="view2">+
    +<page>/view2.jspx</page>+
    +</view>+
    +<control-flow-rule>+
    +<from-activity-id>view1</from-activity-id>+
    +<control-flow-case>+
    +<from-outcome>adfcView2</from-outcome>+
    +<to-activity-id>view2</to-activity-id>+
    +</control-flow-case>+
    +</control-flow-rule>+
    +</adfc-config>+
    When I run the view1.jspx in the embeded WL, all go well, can navigate from view1 to view2.
    But when I created an ear and deployed this ear to a standalone WL, view1 can be displayed successfully, but when I clicked one commandbutton in view1, want to navigator to view2, the page can not be redirected to view2(still show view1.jspx). there is no any error msg in WL Console.
    Did I miss anything for deploying a taskflow app? If I change the view controller to faces-config.xml not adfc-config.xml, all work fine.
    Any info is appreciated.
    Edited by: harth on Oct 25, 2009 7:21 PM

    Hi Harth,
    I guess you are running the jspx page not view activity, check if your url contains .jspx page at the end. If so, run the url without .jspx page at end(which is view id name)
    Eg:
    Give http://<Host_Name>:<Port>/<ContextRoot>/faces/view1 instead of http://<Host_Name>:<Port>/<ContextRoot>/faces/view1.jspxSireesha
    Edited by: Sireesha Pinninti on Oct 25, 2009 8:00 PM

Maybe you are looking for

  • Synching iphone with outlook calendar

    I have just set up a new icloud account and attempted to synch with my outlook calendar and contacts. The outlook was synching with previous icloud account but it is not synching with the new icloud account. Help Please

  • Is there a way to access 11i from outside other than Self service?

    Is there a way to access 11i from outside other than Self service? I could connect any application from inside the firewall (basically router) and can not access screens from outside. Eventhough port forwarding 80 allows us upto initial screen, it do

  • Bbciplayer on wi console

    Before i had infinity put in i could never watch bbciplayer on my WI console because it kept saying ,"insufficient band width". so when the engineer was here installing infinty i told him this and he said that that wouldn't happen any more with infin

  • Webdynpro tables

    In a View, I have 2 Web Dynpro Tables, lets say Entity Table and Lending Unit Table. An Entity has zero or more Lending Units and each Lending Unit belongs to exactly one Entity. In short, a 1:M relationship. Eg. Entity A has Lending units 1,2,3. Ent

  • How to import .mov files that wont play in QT (but play with vlc player)

    I have a batch of .mov files of which QT only plays the audio (video is blank) - same thing when I try to open in Final Cut Express HD. I am able to open these with VLC player. How do I convert these files so that I can edit them in FCE? I am suspect