JSF: Mojarra migration from 2.1 to 2.2 causing a ViewExpiredException

I port my applications from PrimeFaces 3.5.18 + Mojarra 2.1.26 to PrimeFaces 4.0.2 + Mojarra 2.2.4.

When I restart the server, I get a ViewExpiredException.

The server log contains the following: ERROR: MAC did not verify!

I know that by default MyFaces generates a random secret to encode the view state, so every time the server restarts, a new random secret is created. Does Mojarra 2.2 behave the same?

In this case, what context parameters do I need to set? Googling for Mojarra 2.2 context parameters the best I could find was this , but there are no SECRET or MAC_SECRETS parameters like MyFaces

Thanks in advance, Phillip

+3
source share
1 answer

The problem was this: https://java.net/jira/browse/JAVASERVERFACES-2553

I solved it by changing the method of saving state to the server.

+5
source

Source: https://habr.com/ru/post/1533827/


All Articles