Search code examples
amazon-web-serviceswso2wso2-api-managerelastic-load-balancer

WSO2 API Manager store asks for credentials each time want to list applications


I have deployed the WSO2 API Manager with distributed setup and have two nodes of store fronted by an AWS ELB. When I try to access the store via load balancer this issue appears. If I access the store via direct IP for one of the nodes, it works fine. The hazelcast cluster of publisher store nodes also has been connected as expected using aws membership scheme. When we only have one store node fronted by ELB also it works fine.


Solution

  • Load balancer is sending each requests to two stores in round robin manner. You need to enable sticky sessions for aws load balancer. Use JSESSIONID for sticky session.

    aws elb create-app-cookie-stickiness-policy --load-balancer-name my-loadbalancer --policy-name my-app-cookie-policy --cookie-name JSESSIONID