Response.addCookie() not working on OC4j stand alone server

Hi,
I have problem with response.addCookie(). see the code below:
if ((isCookie == null)||(!(isCookie.equals("yes")))) {
String cookiestr="I am OK";
Cookie m_cookie = new Cookie("msign",cookieStr);
m_cookie.setMaxAge(300);
response.addCookie(m_cookie);
This part of the code is in Struts Action class. The read Cookie part is in JSP.
Cookie[] cookies= request.getCookies();
if(cookies != null)
for (int i = 0; i < cookies.length; i++)
if (cookies.getName().equals("msign"))
String infor = cookies[i].getValue();
response.sendRedirect("hellow.jsp");
break;
Add cookie and read cookie work fine on my computer If I runs application on JDeveloper 10g embeded OC4j server. I can see the cookie in the Temporary Internet files
However, I deployed the application on OC4j standalone server, it does not work. response.addCookie() does not work at all. The cookie is not sent to the browser at all. There is no this cookie in Temporary internet file. The page is not directed to hellow.jsp.
Does anybody here know why? Any idea?
Thank you very much!
jfu
Edited by: jfu on Dec 15, 2009 1:26 PM

Hi,
I have problem with response.addCookie(). see the code below:
if ((isCookie == null)||(!(isCookie.equals("yes")))) {
String cookiestr="I am OK";
Cookie m_cookie = new Cookie("msign",cookieStr);
m_cookie.setMaxAge(300);
response.addCookie(m_cookie);
This part of the code is in Struts Action class. The read Cookie part is in JSP.
Cookie[] cookies= request.getCookies();
if(cookies != null)
for (int i = 0; i < cookies.length; i++)
if (cookies.getName().equals("msign"))
String infor = cookies[i].getValue();
response.sendRedirect("hellow.jsp");
break;
Add cookie and read cookie work fine on my computer If I runs application on JDeveloper 10g embeded OC4j server. I can see the cookie in the Temporary Internet files
However, I deployed the application on OC4j standalone server, it does not work. response.addCookie() does not work at all. The cookie is not sent to the browser at all. There is no this cookie in Temporary internet file. The page is not directed to hellow.jsp.
Does anybody here know why? Any idea?
Thank you very much!
jfu
Edited by: jfu on Dec 15, 2009 1:26 PM

Similar Messages

  • To set environment variables in OC4J stand alone server

    Hello,
    I deployed my application to OC4J standalone server. I need to set some environment variables, which will be accessed from my application.
    Could you please let me know, how to set the environment variables for the application which runs from stand alone OC4J server ?
    Thanks!

    Hello,
    Thanks for providing me the information. Here is what I am trying to accomplish...
    I have a Web service application which in turn calls a Java application and which invokes a third party application. The third party application expects some environment variables to be set.
    I set these environment on my local machine, and when I executed the Java application as a standalone application within JDeveloper - it works. But when I deployed this application to the stand alone OC4J server and when I execute the application, the third party application is not getting the environment variables correctly. (that's what I am guessing here..)
    I just put System.getenv() to get the environment variables and the value is displaying correctly.
    As Jacco suggested, I passed these env. variables thru' the startup of OC4J server.
    (i.e.) java -D<variable1>=value1 -D<variable2>=<value2> -jar oc4j.jar and still didn't work.
    Do I have to pass these values thru' any XML file within OC4J server..
    Any thoughts ? I appreciate if you can provide some input.
    Thanks!

  • Web Services - Issue with running OC4J stand alone server from JDeveloper

    I created a stand alone OC4J App. server instance in JDeveloper. I deployed my Webservice (WebServices.deploy) to that OC4J server.
    Now I want to test my web service. I opened a browser window and I specfied the URL as
    http://localhost:<RMI Port#>/<Project1>-context-root/<Webservice name>.
    Default RMI Port#23791.
    http://localhost:23791/<Project1>-context-root/<Webservice name>.
    and I am getting the following error message
    ã vInvalid protocol verification, illegal ORMI request or request performed with an incompatible version of this protocolvInvalid protocol verification, illegal ORMI request or request performed with an incompatible version of this protocol.
    Could you please let me know, what's going on.
    Thanks!

    OK, so there's two threads in this email.
    1. When using a Web browser client and an OC4J standalone instance, the default address of the OC4J website is http://host:8888/.
    The port you keep referring to is the ORMI port. That is a different protocol that is used with EJBs, and our remote deployment mechanism. As you have observed, JDeveloper uses it to deploy to the OC4J instance.
    2. The root problem you are seeing is related to the message you posted on the console.
    OC4J 10g (10.1.3) Default Web Site. Application: bc4j does not exist. Error creating Web application: webapp
    Because this web app is misconfigured, its not starting so you can't access it.
    In the j2ee/home/config/default-web-site.xml file, there is a reference to an application called BC4J -- which is not available on the server as a deployed application.
    So you need to correct that situation -- BC4J is not normally present in a vanilla OC4J standalone distribution.
    You can try editing the j2ee/home/config/default-web-site.xml file and remove the <web-app> entry that mentions BC4J and then try starting OC4J.
    If you don't have a lot of time invested in configuring the instance, you could also try extracting oc4j_extended.zip again and starting with a fresh one.
    cheers
    -steve-

  • Not able to download OC4J stand-alone user's guide

    Hi,
    I tried to download Oracle9iAS J2EE container (OC4J) stand-alone users guide ( The file name is
    http://otn.oracle.com/tech/java/oc4j/pdf/oc4j_so_usersguide_r2.pdf). It is a pdf file. It shows the first page of the document in the browser. When try to go to other pages, it hangs-up and says
    " A File I/O occurred. Connection Timed-out"
    after some time.
    Could u please correct it ? If not, atleaset, could u let me know whether atleast HTML version is available ?
    tnr,
    Sai

    Hi,
    try the following URL, there can you select which version of the docs you would like to display:
    http://otn.oracle.com/documentation/ias.html
    Thanks
    @

  • Is there a way to get the calculator from the dashboard to appear along with other programs?  Can anyone recommend a calculator which will work as a stand alone app?

    AS it stands now, in order to use the calculator that comes with the Dashboard, you cannot read from a list of numbers in, lets say, word or excel. The dashboard is full screen and nothing can stand along side it. Is there a way to get the calculator from the dashboard to appear along with other programs?  Can anyone recommend a calculator which will work as a stand alone app?

    there is one, just search with spotlight "Calculator".
    It works great!
    Hope this helps.

  • Response Groups not working

    Hi there
    My environment is a single Lync 2013 Front End Server installed on Server 2012.
    It works since a year and now we want to use some response groups. I created 2 of them and everything seems fine but i cant call these groups. Not from internal and also not from external.
    The clients shows an 500 internal server error with ID 26017.
    So i traced the whole thing on the Front End Server. It seems the Response Group Service cant work with the local SQL Server. I see three error messages.
    1. TL_ERROR(TF_COMPONENT) [2]0B90.37A8::07/23/2014-06:38:39.119.000002fb (RgsClientsLib,MatchMakingLocator.GetActiveInstanceFromDB:683.idx(479))
    (0000000000150BA8)No instance registered as the active instance!
    2. TL_ERROR(TF_COMPONENT) [1]1E08.2910::07/23/2014-06:38:42.462.00000a34 (RgsHostingFramework,CallControlManager.HandleAudioVideoCall:2049.idx(619))
    (000000000362D054)Call is declined because Call Control is not started.
    3. TL_WARN(TF_COMPONENT) [1]0B90.0B7C::07/23/2014-06:38:48.053.00000f2d (RgsClientsLib,MatchMakingLocator.GetActiveMatchMakingInstance:683.idx(301))
    (0000000000150BA8)There is currently no active MatchMaking instance in the pool.
    The Lync Server Event Log shows this error when the Response Group Service starts:
    LS Response Group Service ID 31067
    Lync Server 2013, Response Group Service Match Making could not find the Contact object used for subscribing to agents' presence.
    Cause: The application has not been properly activated or the Contact object was deleted.
    Resolution:
    Deactivate and then activate the application for this pool.
    Is there a way to reinstall / reconfigure the whole response group service incl. the active directory objects?
    I hope somebody could help
    Regards
    Andreas

    Have you seen this thread:
    http://social.technet.microsoft.com/Forums/lync/en-US/cd25ddec-6e1e-4d58-9a9a-a530abfa82e3/response-groups-not-working?forum=ocsclients ?
    He ran Get-CsApplicationEndpoint and received a warning that let him to a resolution.
    Short of that, I'd rerun step 2 in the deployment wizard and restart services when you can to see if I could jog anything loose.
    Please remember, if you see a post that helped you please click "Vote As Helpful" and if it answered your question please click "Mark As Answer".
    SWC Unified Communications

  • General: can the OAF work as a stand alone application

    hi...
    can the OAF work as a stand-alone application??
    please help

    Thanks.
    OAF provides Developers with templates that utilise Oracle EBusiness technologies, for security, session handling, etc so cannot
    be used outside the eBusiness environment.
    The JDev version for eBiz is a specific eBiz version, but if you have non-eBiz programming requirement, you can still use this JDeveloper environment to create non-eBiz integrated applications. Alternativel
    you can use a seperate install of JDeveloper/ADF

  • Maximum concurrent user on OC4J Stand Alone ?

    Hi All,
    I have questions on OC4J :
    1) How many concurrent user that can be supported by OC4J 10.1.3 Stand Alone ?
    2) What is different between OC4J Stand Alone and OC4J Stand Alone that comes with JDev ?
    Thank you,
    xtanto

    Hi,
    1.) This depends on your application and of the configuration of OC4J (for example JVM parameter).
    2.) Afaik there is no difference between both OC4J. OC4J which comes with JDev
    is the J2EE runtime environment for JDeveloper. For development purposes it is much easier to use the embedded OC4J instead of deploying first the application to a remote OC4J.
    Regards
    Kersten

  • How to use dbxml as a stand alone server?

    Dear All
    Is there any way to launch dbxml as a stand alone server?
    What I want to do is the following.
    I am using PHP and creating a web site on which users can search information stored in dbxml.
    So far each time client (browser) come to the page,
    php code opens the database and containers as
    $env = new Db4Env();
    $env->open(path, DB_CREATE | DB_INIT_LOCK | DB_INIT_LOG | DB_INIT_MPOOL | DB_INIT_TXN);
    I wonder if I can run the dbxml as like daemon, so that I do not need to open the database each time,
    and only thing I need to do is to connect to the server.
    Thank you for any advise or comments in advance.
    oyasai

    not only should you do this, but you have to do it to make sure that your database does not get corrupted in a multi request/multi threaded environment. However, there are weird requirements when working with recovering databases and corruption, especially in a dynamic language. We are using python and then coded a front end server with the Twisted framework with a lot of success (single threaded access to manage corruption). Then, all of our web apps talk to the twisted server in the same way as you would a mysql server. It is python, but if you are interested in working with it I can try to get this code out to you personally (I've been wanting to open source the code for a while now) - or if you want to do the same in php I can get you the big concepts which make it different than a traditional mysql or http server.
    Email me at eleddy at janushealth dot com if you are interested - it could be a long discussion :)
    hth,
    eleddy

  • Issue while deploying dynamic region to stand alone server

    Hi,
    In my application there is one page I have panel splitter, where i have drag and dropped menu-taskflow as regionModel, and created dynamic region on second facet panel.
    <af:region value="#{bindings.menutaskflow1.regionModel}" id="r1"/>
    <af:region value="#{bindings.dynamicRegion4.regionModel}" id="r2"/>
    I have created application level class to handle dynamic region loading.
    This settings are working fine when i run application with integrated web logic server, When I deployed my application to stand alone server, its giving me exception as
    java.lang.IllegalStateException: The expression "#{bindings.menutaskflow1.regionModel}" (that was specified for the RegionModel "value" attribute of the region component with id "r1") evaluated to null.
    This is typically due to an error in the configuration of the objects referenced by this expression.
    If it helps, the expression "#{bindings.menutaskflow1}" evaluates to "null".
    If it helps, the expression "#{bindings}" evaluates to "null". Now using an empty RegionModel instead.
         at oracle.adf.view.rich.component.fragment.UIXRegion.getRegionModel(UIXRegion.java:439)
         at oracle.adfinternal.view.faces.taglib.region.RegionTag.doStartTag(RegionTag.java:109)
         at jsp_servlet.__editopportunity_jspx._jspx___tag18(__editopportunity_jspx.java:923)
         at jsp_servlet.__editopportunity_jspx._jspService(__editopportunity_jspx.java:452)
         at weblogic.servlet.jsp.JspBase.service(JspBase.java:34)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:183)
         at weblogic.servlet.internal.RequestDispatcherImpl.invokeServlet(RequestDispatcherImpl.java:526)
         at weblogic.servlet.internal.RequestDispatcherImpl.forward(RequestDispatcherImpl.java:253)
         at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:410)
         at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
         at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
         at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
         at org.apache.myfaces.trinidad.context.ExternalContextDecorator.dispatch(ExternalContextDecorator.java:44)
         at org.apache.myfaces.trinidadinternal.context.FacesContextFactoryImpl$OverrideDispatch.dispatch(FacesContextFactoryImpl.java:267)
         at com.sun.faces.application.ViewHandlerImpl.executePageToBuildView(ViewHandlerImpl.java:473)
         at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:141)
         at javax.faces.application.ViewHandlerWrapper.renderView(ViewHandlerWrapper.java:189)
         at org.apache.myfaces.trinidadinternal.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:193)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._renderResponse(LifecycleImpl.java:710)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:273)
         at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:205)
         at javax.faces.webapp.FacesServlet.service(FacesServlet.java:266)
         at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)
         at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)
         at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)
         at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:191)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:97)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:420)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:247)
         at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:157)
         at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at oracle.dms.wls.DMSServletFilter.doFilter(DMSServletFilter.java:330)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)
         at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.doIt(WebAppServletContext.java:3684)
         at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3650)
         at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)
         at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:121)
         at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2268)
         at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2174)
         at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1446)
         at weblogic.work.ExecuteThread.execute(ExecuteThread.java:201)
         at weblogic.work.ExecuteThread.run(ExecuteThread.java:173)
    I tried to update bindings with data level binding as
    <af:region value="#{data.view_MenuPageDef.menutaskflow1.regionModel}" id="r1"/>
    <af:region value="#{data.view_MenuPageDef.dynamicRegion4.regionModel}" id="r2"/>
    but it is rendering empty page with another exception..
    Please help
    Regards,
    Meera

    Hi,
    Check
    Runtime errors with ADF Dynamic region
    java.lang.IllegalStateException: The expression "#{bindings.dynamicRegion1.
    Problem with bounded task flow: binding lost?

  • 11g HTTP Stand Alone Server Media

    Does anyone know where the 11g HTTP Stand Alone Server media is located for download. It used to come with the companion CD in 10g, but this is the statement in the Oracle Documentation - "Oracle HTTP Server: Starting with Oracle Database 11g, Oracle HTTP Server is available on a separate media shipped with Oracle Database. In the previous releases, this product was available as a Companion CD component.".
    Can anyone provide a link to the download? As its not with the 11g database download....

    But there is still a copanion CD (it is called examples now).
    http://www.oracle.com/technology/software/products/database/oracle11g/111060_linx8664soft.html
    Dim

  • Old Netscape console 4.2 not working properly with new Directory Server 5.2

    After successfully installing Messaging Server 5.2 and applying patch 2, the old Netscape Console doesn't work properly, I tried running the script which is given in the link
    http://docs.sun.com/source/816-6734-10/index.html
    which hobbles the server by creating a set of dummy jar files in order for the directory server console not making any changes on the messaging server. At first I got these messages:
    Failed to install a local copy of msgadmin52.jar or one of its supporting files: not a ZIP file (END header not found)
    I got the same message for these 2 files:
    admserv42.jar
    msgadmin52.jar
    After that I made real dummy jar files using a zero-length file I created with touch and I got these messages:
    class com.netscape.management.admser.AdminServer not found
    After that I erased all the files created by the script and I get these messages:
    failed to install a copy of admserv51.jar or one of its supporting files: null
    failed to install a copy of msgadmin.jar or one of its supporting files: msgadmin52.jar not found at http://192.168.10.205:5001/
    and for admserv42.jar I get the same message
    Does anyone have a clue on what to do next??
    thanks in advance
    Eduardo

    The thing is that the netscape console 4.5 won't work properly with messaging server 5.2, and the directory server console is not working properly for the directory server. I already know the limitations about these consoles since it is explained in the doc where the procedure of migrating from a 4.x directory server to 5.1. I

  • Swf is not working properly when upload to server

    I develop 1.swf which is having 3 buttons each one having
    anather .swf to call 2.swf, 3.swf respectively.
    This application is running perfectly on my PC, but
    While uploading the swf to server the 2.swf and 3.swf is
    not running. Can any one tell how to recover from this kind
    of problem.

    justbipin wrote:
    > basically my code working perfectly,
    > but its not working properly when upload to server
    > can anybody having any ref. or link to solve this
    issues.
    why is that we insist on seeing the source file ?
    There is no one way of doing things in flash and no one can
    help
    you based on "does not work description".
    This is way to broad of a subject to even try to guess.
    Same as asking "my car does not work, what's up with
    that"....
    Please upload the problematic file and provide url for us to
    check.
    Otherwise you need to try to troubleshoot it yourself as we
    can't
    guess from here what possibly is wrong with that file.
    Regards
    Urami
    Happy New Year guys - all the best there is in the 2006 :)
    <urami>
    http://www.Flashfugitive.com
    </urami>
    <web junk free>
    http://www.firefox.com
    </web junk free>

  • PI 7.0 Java stack config of the stand-alone server to  new cluster system

    Hi colleagues,
    we have a PI installation in stand alone server (SAP with abap +
    java and Oracle in the same server)
    The system number of the ABAP stack is 00, and we are conecting to the
    Java stack to the for example the URL
    http://hostname:50000/rep/start/index.jsp
    We have installed a new PI in a MSCS and in some weeks, we´ll have to
    copy the database and configuration of the stand-alone server to the
    new cluster system. In the SAP PI installation on the MSCS, we have
    confirmed that with the ABAP stack, we won´t have any issue because the
    ASCS has the system number 00 (message server), so we only have to
    install a SAP system in each nodes without care these new system
    numbers because we are configuring a Logon group but the question is in
    the Java stack... The SCS (service in the cluster) has the 01 system
    number...
    What is the best way to keep the same URL to the Java stack that in the
    stand-alone server? (remember:
    http://hostname:50000/rep/start/index.jsp )
    Have we to install a Webdispatcher in the MSCS and one Java stack in
    each node of the cluster? we think that is right but we have a lot of
    doubts about the URL, the files of the Java (if they are stored in
    local disk in one node, how are they replicated to the second node?)
    and so on....
    Could you give us any suggestion to make the "migration" from the stand-alone to a cluster in a transparent way for the users?
    Thanks in advanced and kind regards !!
    Victor

    Thanks a lot.
    For information
    Our central SLD is on a standalone system
    However slave SLD (to ensure autonomy and HA for production XI system) will be deployed on Java separated hardware system of Xi production system.
    On master SLD all systems are described and all machine are linked with it (SLDAPICUST) except production XI one
    On slave SLD, all data of master one are replicated and only XI system is linked with (SLDAPICUST)

  • ODI 11g 11.1.1.7 with Win64 bit OS : Starange problem : Right click does not work for Create new data server in Topology.

    ODI 11g 11.1.1.7 with Win64 bit OS : Strange problem : Right click does not work for Create new data server in Topology.
    On right click nothing happens at all. I have  reinstall the ODI multiple times with right installer. issue persist.
    Please help.

    Hi,
    Did you use the generic installer or the win32 one ? You should use the former with Win64.
    You can also check that your version of Java is supported in the certification matrix.
    Regards,
    JeromeFr

Maybe you are looking for

  • Need to convert App Store from Swiss to uk?

    I need to convert the App Store from Swiss to uk?

  • How can i know the no .of  connections are used in the connection pool

    Hi I am using tomcat connection pool in my project .but how can i know how many connections are used by my project .how can i know how many connections are used plez help me

  • Role Migration Error in EP6SP2_P4_HF7

    We are looking to migrate Roles from R/3 (4.7) to Portals.  When we try the Role Upload utility we get the following Java error. I greatly appreciate any help. - PK com.sapportals.portal.prt.component.PortalComponentException: Error in service call o

  • Setting for enjoy transactions

    Dear all, could any body help me in this. how do i get edit - new entries option in Img-Materials Management-Inventory Management and Physical Inventory-Settings for Enjoy Transactions-Settings for Goods Movement-Setting for Transactions and Referenc

  • Installing Client Combo 10.7.4 through Terminal?

    This is totally unacceptable!! I've had this Thunderbolt Update problem since Tuesday morning and still pulling my hair out from it. I have run out of options in fixing this. Ive been using SL for over a year and only upgraded to Lion last week befor