Quantcast
Channel: Active questions tagged servlets - Stack Overflow
Viewing all articles
Browse latest Browse all 675

Problems with migration from WAS 6.1 to WAS 7.0 cookie is always null

$
0
0

I have this problem:

  1. I migrate my applications from WAS 6.1 to WAS 7.0 using migration tool in C:\Program Files\IBM\SDP\runtimes\base_v7\bin\migration
  2. The application was running just fine in 6.1 server, but when I migrated it, there is a problem with one Cookie that I need for getting the division from the user.
  3. After debugging a while, I realized that the Cookie is getting created, but for a reason a don't know the Cookie is not being put into the HttpServletResponse, so when I try to retrieve the value for the Cookie it says that it is null.

Here's the snippet of code used to do this:

public static void setDivisionCookie( String div, HttpServletResponse res ){    Cookie cookie = new Cookie(USER_DIVISION_COOKIE_NAME, div);    cookie.setMaxAge(Integer.MAX_VALUE);    cookie.setPath("/");    res.addCookie( cookie );}

I have to say that the application is running with Struts (these are the jar's I'm using struts-1.2.9, struts2-core-2.1.8.1, struts-taglib-1.3.8)


Viewing all articles
Browse latest Browse all 675

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>