starting api before discovery service