Skip to content

Commit

Permalink
Update ClientConnectionHandler.java
Browse files Browse the repository at this point in the history
Fixed the problem with the Round-Robin Scheduling
  • Loading branch information
vinay92 committed Apr 19, 2015
1 parent 48396a1 commit b6ee6f7
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions src/edu/tomr/loadbalancer/ClientConnectionHandler.java
Original file line number Diff line number Diff line change
Expand Up @@ -67,8 +67,9 @@ private synchronized String getIPAddress() {
String IPAddress = null;
try{
if(turnOf == ConfigParams.getIpAddresses().size() - 1){
turnOf = 0;
IPAddress = ConfigParams.getIpAddresses().get(turnOf);
turnOf = 0;

}
else{
IPAddress = ConfigParams.getIpAddresses().get(turnOf);
Expand All @@ -84,4 +85,4 @@ private synchronized String getIPAddress() {

}

}
}

0 comments on commit b6ee6f7

Please sign in to comment.