This whole code for obtaining a new instance of DiscoveryStrategy could be moved to createDeployment() as the strategy is not used anywhere else.