@pradeeban @monteiro I do not understand this algorihtm alwasy returns return this.defaultDeploymentIndex

Why are you computing the other stuff for?