Reputation: 2698
I have a worklight application that connects to a commerce backend.
I have a requirement that even if the user is not logged in, i still have to request guest tokens from the backend server and use them on all guest requests.
Right now we are doing this by using an worklight adapter login session. But the problem is that when the user wants to login to their account, in the backend we have to do a WL.Client.logout, followed by WL.Client.login to reset the WL.Server.setActiveUser with the new credentials.
There seems to be a lot of room for error doing it this way. But if the user does not complete the transaction, i have to re-login as guest.
Is there another way
Upvotes: 0
Views: 24