discovery: fix discovery for not working on customized discovery service