Refactoring to make tomcatManager a jquery widget