ex.printStackTrace();
if(slpLog != null) slpLog.error("Error during discovery", ex); else ex.printStackTrace();
    protected void locateServices() {        if(discoveryDelay != 0) {            try {                Thread.sleep(discoveryDelay);            }catch(InterruptedException ie) { }        }        while(runThread) {            try {                if(serviceType != null) {                    discoveryResults = locator.findServices(serviceType, scope_list, searchFilter);                }                stopWaiting();            }catch(ServiceLocationException ex) {                // error during discovery.                ex.printStackTrace();                // stop thread...                runThread = false;                stopWaiting();            }            if(discoveryInterval == 0) {                runThread = false;            }            else {                try {                    Thread.sleep(discoveryInterval);                }catch(InterruptedException ie) { }            }        }    }