System.out.println("Agent: " + data.getName());
  public ComponentData addComponentData(ComponentData data) {    System.out.println("Agent: " + data.getName());    StringBuffer assemblyMatch = null;    String name = data.getName();    int dotPos = name.lastIndexOf('.');    if (dotPos >= 0) {      name = name.substring(dotPos + 1);    }    substitutions.put(":agent_name", name);    // Get Plugin Names    try {      Connection conn = DBUtils.getConnection();      try {	Statement stmt = conn.createStatement();	        dbp.setDebug(true);	String query = dbp.getQuery(QUERY_PLUGIN_NAME, substitutions);	ResultSet rs = stmt.executeQuery(query);	while(rs.next()) {	  GenericComponentData plugin = new GenericComponentData();          String pluginClassName = rs.getString(1);	  plugin.setType(ComponentData.PLUGIN);          plugin.setClassName(pluginClassName);	  plugin.setParent(data);	  plugin.setOwner(this);	  plugin.setName(pluginClassName);	  data.addChild(plugin);	}      } finally {	conn.close();      }    } catch (Exception e) {      e.printStackTrace();      throw new RuntimeException("Error" + e);    }    System.out.println("Done");    return data;  }