My project (on angularJs) implementation is done in a way that a single webpage application is deployed on a load balancer with 2 nodes, I am not able to figure out a solution for the below problem.
Implementation:
Here is the scenario: (Note: The same User is logging-in from client1, client2 & client3)
Client1 -> lands and logs-in on node1 -> token1 is created
Client2 -> lands and logs-in on node2 -> token2 is created
Now suppose node1 goes down (due to some reasons),
Client3 -> lands on node2 by default -> Now,
Note: Since there is a token already generated on node2 for the user and the session here is active too, so
Questions
I had the same discussion with my development team and here is the answer just in case anyone might need it in the future