better java service wrapper download function