public static ServerInstanceAvailableModules getDistributeModules(Project serverInstance) {

    Project suite = getServerSuiteProject(serverInstance);
    if (suite == null) {
      return null;
    }
    DistributeModulesManager m = suite.getLookup().lookup(DistributeModulesManager.class);

    if (m == null) {
      return null;
    }
    return m.get(serverInstance);
  }
  public static ServerInstanceAvailableModules getDistributeModules(String uri) {
    Project suite = getServerSuiteProject(uri);
    if (suite == null) {
      return null;
    }
    DistributeModulesManager m = suite.getLookup().lookup(DistributeModulesManager.class);

    //        DistributeModulesManager m = getInstance(uri);
    if (m == null) {
      return null;
    }
    String p = SuiteUtil.extractInstancePath(uri);
    if (p == null) {
      return null;
    }
    return m.get(p);
  }