restructuring to resolve a duplicate class on classpath issue