This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Build: NetBeans IDE 8.0 (Build 201403101706) VM: Java HotSpot(TM) 64-Bit Server VM, 24.51-b03, Java(TM) SE Runtime Environment, 1.7.0_51-b13 OS: Windows 8 User Comments: pns: Was trying to add the latest promoted glassfish version (4.0.1 m4), after selecting the folder where I have the glassfish server installed, I got this exception. The glassfish server is in "C:\Program Files\glassfish-4.0.1" and it's working with NetBeans 7.4 Stacktrace: java.lang.NullPointerException at java.net.NetworkInterface.getInterfaceAddresses(NetworkInterface.java:168) at org.glassfish.tools.ide.utils.NetUtils.getHostIP4s(NetUtils.java:418) at org.netbeans.modules.glassfish.common.wizards.AddDomainLocationVisualPanel.<init>(AddDomainLocationVisualPanel.java:94) at org.netbeans.modules.glassfish.common.wizards.AddDomainLocationPanel.getComponent(AddDomainLocationPanel.java:155) at org.netbeans.modules.glassfish.common.wizards.ServerWizardIterator.current(ServerWizardIterator.java:235) at org.netbeans.modules.server.ui.wizard.AddServerInstanceWizard$AddServerInstanceWizardIterator.current(AddServerInstanceWizard.java:346)
Created attachment 146152 [details] stacktrace
This code should try to detect all IP4 addresses on machine where netbeans are running. Looks like it msy have some issues on Windows. Were you able to register it or is wisard not working at all for you? Unfortunately java.net.NetworkInterface.getInterfaceAddresses(NetworkInterface.java:168) is JDK so I can't do much with NPE there. But I'll add somethng to handle it in org.glassfish.tools.ide.utils.NetUtils where method can respond with empty list + some log message instead of throwing an exception.
Just ran a quick test and it seems the problem is the JVM argument "-J-Djava.net.preferIPv4Stack=true", If I ommit it I no longer get the exception (and yes with that argument I get the exception everytime and cannot finish the wizard). Nevertheless, I run 7.4 with the same JDK and with that argument and have no problems with there.
Well, GF plugin was not touched since 7.4 so I would expect the same issues in both 7.4 and 8.0. I'll update affected jar tomorrow and it will be attached here to let you test it.
Created attachment 151428 [details] stacktrace ADD SERVER INSTANCE->DOWNLOAD AND INSTALL GLASSFISH SERVER-> CLICK NEXT the next button is not working.....
*** Bug 245310 has been marked as a duplicate of this bug. ***
Can you share some information about your network interfaces setup?
This is blind fix as I was not able to reproduce the issue. Feel free to reopen. web-main 527dd3496329.
Integrated into 'main-silver', will be available in build *201504290001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-silver/rev/527dd3496329 User: Petr Hejl <phejl@netbeans.org> Log: #243061 - NullPointerException at java.net.NetworkInterface.getInterfaceAddresses