I'm trying to migrate authentication in my seam application from using a login page to a get request (containing a header for the user). I'm facing a weird problem when using login page to authenticate I'm able to extract the user through the entityManager, but when using the get request the entityManager is unable to find the entity (user). For authentication using get request i used two approaches:
Creating a fake login page which triggers the authentication process
Creating a servlet which gets the request and starts the authentication process
I read a lot about how seam manages the persistence context, but i didn't find a single explanation which make this issue clear. Do you have any ideas? suggestions? or even guesses?