Expand my Community achievements bar.

Dive into Adobe Summit 2024! Explore curated list of AEM sessions & labs, register, connect with experts, ask questions, engage, and share insights. Don't miss the excitement.
SOLVED

HttpSession in AEM 6.2

Avatar

Level 3

Hi, I try to use HttpSession to store some values but it is not working in AEM 6.2

Here is my test code when you click next you should see "my new value" instead null

<!doctype html>

<%@ page session="true" %>

<html>

<%

    //HttpSession sessionCustom=request.getSession(false);

    String oldValue = (String) session.getAttribute("val");

    session.setAttribute("val", "my new value");

%>

<body>

    <p>our old value <%= oldValue %></p>

    <a href="">next page</a>

</body>

</html>

</body>

</html>

1 Accepted Solution

Avatar

Correct answer by
Level 4

This is bug in jetty version.Solution upgrade jetty jar to version  3.4.0-B002

View solution in original post

8 Replies

Avatar

Level 1

I have the same issue. I have some servlets that read objects from session. But I noticed the session ID keep changing in every request. Every time AEM 6.2 creates a new session. It looks AEM 6.2 doesn't support httpsession at all. Can someone please help?

Avatar

Level 1

Hi,

we run into the same issue while trying to upgrade our app from 5.6 to 6.2. Wondering if you found a solution yet or not. I just submitted a ticket to Adobe, but not sure on how soon they will respond on that.

Thanks!

Varma.

Avatar

Level 2

You're not alone, same issue here. Will open a ticket as well

Avatar

Level 1

I would like to hear if anyone is using any temporary solution to get around it and at least be able to continue with the development efforts.

Avatar

Level 2

This is a critical bug at the very foundation of app servers. Any workaround here would be essentially a hack. Our current hack is to save session values in the respository

Avatar

Correct answer by
Level 4

This is bug in jetty version.Solution upgrade jetty jar to version  3.4.0-B002

Avatar

Level 2

Sh1ju​ your solution works. Might even be included in Service Pack 1