Fix some classpath issues. Also add Util methods to compute URL's for

smartcloud sample.