1.1 --- a/compapp.manager.jbi/src/org/netbeans/modules/sun/manager/jbi/util/ServerInstanceReader.java Sun Jun 22 23:34:38 2008 +0200
1.2 +++ b/compapp.manager.jbi/src/org/netbeans/modules/sun/manager/jbi/util/ServerInstanceReader.java Wed Jun 25 10:15:37 2008 +0200
1.3 @@ -52,7 +52,9 @@
1.4 import org.xml.sax.EntityResolver;
1.5 import java.io.File;
1.6 import java.io.IOException;
1.7 +import java.net.InetAddress;
1.8 import java.net.URL;
1.9 +import java.net.UnknownHostException;
1.10 import java.util.ArrayList;
1.11 import java.util.List;
1.12 import javax.xml.parsers.DocumentBuilder;
1.13 @@ -95,7 +97,9 @@
1.14 }
1.15
1.16 /**
1.17 - * Gets a list of server instances in the server config file.
1.18 + * Gets a list of server instances in the server config file that meet our
1.19 + * assumption: no null data for host and location... see
1.20 + * AppserverJBIMgmtController.isCurrentInstance.
1.21 */
1.22 public List<ServerInstance> getServerInstances() {
1.23 if (instances == null) {
1.24 @@ -166,7 +170,9 @@
1.25 }
1.26 }
1.27
1.28 - instances.add(instance);
1.29 + if (instance.getHostName() != null && instance.getLocation() != null) {
1.30 + instances.add(instance);
1.31 + }
1.32 }
1.33 } catch (Exception e) {
1.34 e.printStackTrace(System.err);