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.

Bug 145749 - NumberFormatException: null
Summary: NumberFormatException: null
Status: VERIFIED FIXED
Alias: None
Product: serverplugins
Classification: Unclassified
Component: Sun Appserver 9 (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: _ pcw
URL: http://statistics.netbeans.org/except...
Keywords:
Depends on:
Blocks:
 
Reported: 2008-09-01 02:16 UTC by Lukas Jungmann
Modified: 2008-09-17 15:38 UTC (History)
3 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 102636


Attachments
stacktrace (862 bytes, text/plain)
2008-09-01 02:16 UTC, Lukas Jungmann
Details
nbattrs (2.19 KB, text/plain)
2008-09-01 02:24 UTC, Lukas Jungmann
Details
stacktrace (38 bytes, text/plain)
2008-09-01 06:06 UTC, rajivderas
Details
stacktrace (862 bytes, text/plain)
2008-09-01 06:09 UTC, rajivderas
Details
patch (2.13 KB, text/plain)
2008-09-01 19:24 UTC, _ pcw
Details
stacktrace (38 bytes, text/plain)
2008-09-03 17:06 UTC, esmithbss
Details
stacktrace (862 bytes, text/plain)
2008-09-03 20:09 UTC, ieising
Details
stacktrace (862 bytes, text/plain)
2008-09-03 20:09 UTC, ieising
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Lukas Jungmann 2008-09-01 02:16:03 UTC
Build: NetBeans IDE Dev (Build 20080831185227)
VM: Java HotSpot(TM) Client VM, 1.5.0_13-119, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_13-b05-237
OS: Mac OS X, 10.5.4, i386

User Comments: 
-just started IDE on mac, prehaps w/ old userdir (?)

Stacktrace: 
java.lang.NumberFormatException: null
        at java.lang.Integer.parseInt(Integer.java:415)
        at java.lang.Integer.parseInt(Integer.java:497)
        at org.netbeans.modules.j2ee.sun.ide.dm.ServerInstanceDescriptorImpl.getHttpPort(ServerInstanceDescriptorImpl.java:64)
        at org.netbeans.modules.j2ee.deployment.devmodules.api.ServerInstance$Descriptor.getHttpPort(ServerInstance.java:205)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWebServiceURL(JaxWsNode.java:376)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWsdlURL(JaxWsNode.java:615)
Comment 1 Lukas Jungmann 2008-09-01 02:16:11 UTC
Created attachment 68755 [details]
stacktrace
Comment 2 Lukas Jungmann 2008-09-01 02:24:59 UTC
Created attachment 68756 [details]
nbattrs
Comment 3 Lukas Jungmann 2008-09-01 02:29:45 UTC
no..., happens also with clean/new userdir
Comment 4 rajivderas 2008-09-01 06:06:39 UTC
Build: NetBeans IDE Dev (Build 200808311401)
VM: Java HotSpot(TM) Client VM, 11.0-b11, Java(TM) SE Runtime Environment, 1.6.0_10-beta-b21
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
java.lang.NumberFormatException: null
Comment 5 rajivderas 2008-09-01 06:06:48 UTC
Created attachment 68762 [details]
stacktrace
Comment 6 rajivderas 2008-09-01 06:09:31 UTC
Build: NetBeans IDE Dev (Build 200808311401)
VM: Java HotSpot(TM) Client VM, 11.0-b11, Java(TM) SE Runtime Environment, 1.6.0_10-beta-b21
OS: Windows XP, 5.1, x86

User Comments: 


Stacktrace: 
java.lang.NumberFormatException: null
        at java.lang.Integer.parseInt(Integer.java:415)
        at java.lang.Integer.parseInt(Integer.java:497)
        at org.netbeans.modules.j2ee.sun.ide.dm.ServerInstanceDescriptorImpl.getHttpPort(ServerInstanceDescriptorImpl.java:64)
        at org.netbeans.modules.j2ee.deployment.devmodules.api.ServerInstance$Descriptor.getHttpPort(ServerInstance.java:205)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWebServiceURL(JaxWsNode.java:376)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWsdlURL(JaxWsNode.java:615)
Comment 7 rajivderas 2008-09-01 06:09:35 UTC
Created attachment 68763 [details]
stacktrace
Comment 8 Milan Kuchtiak 2008-09-01 10:09:31 UTC
I noticed SunDeploymentManager.getNonAdminNumber returns null at the moment :

    public String getNonAdminPortNumber() {
        return nonAdminPortNumber;
    }

The message is really annoying. Now we get this warning message every time the WS Node is clicked.
It's related to issue 99155 (ServiceInstanceDescriptor API implementation).
Comment 9 _ pcw 2008-09-01 18:22:14 UTC
Wow, that's really annoying.  I'm really sorry.

(1) I didn't realize this code was going live as soon as I implemented it.  I guess I didn't test the right option to
get it activated.
(2) There is a catch for the NFE for this edge case -- oddly enough the IDE is behaving as if it isn't there, as I got a
trace suggesting this was caught here:  "[catch] at java.awt.SequencedEvent.dispatch(SequencedEvent.java:101)"
Comment 10 _ pcw 2008-09-01 19:24:16 UTC
Created attachment 68813 [details]
patch
Comment 11 _ pcw 2008-09-01 19:30:09 UTC
I can't nurse a build right now, so I attached a patch that will resolve the annoyance.  Anyone else can apply this if
they want to.

I'll deal with the null tomorrow.  There is a better way of handling that case.

I'm still a bit confused by how the catch for the NFE could be ignored but maybe the trace display code simply doesn't
work the way I thought it did.
Comment 12 _ pcw 2008-09-01 19:34:22 UTC
One more thing - I'm pretty sure you can prevent the exception by starting the server (GlassFish V2).  IIRC the null
case can only happen when the server is not running.
Comment 13 Petr Hejl 2008-09-01 22:10:56 UTC
Hi Peter,
just small note. Afaik the exception is probably not ignored. I think that NB implementation of the Logger brings up the
stacktrace window on Level greater or equal to WARNING (when assertions are enabled - aka dev builds). I think the
proper solution would be to return default on null while logging message with INFO level (if this is so often).

These are just things that came to my mind and I'm not absolutely sure about this - you'll have to test it.
Comment 14 _ pcw 2008-09-02 20:03:27 UTC
Fixed.
Comment 15 rajivderas 2008-09-03 14:34:55 UTC
Still exist in Dev Build 200809021401 when refactoring rename a webservice in ejb module
Comment 16 esmithbss 2008-09-03 17:06:26 UTC
Build: NetBeans IDE Dev (Build 200809020201)
VM: Java HotSpot(TM) Client VM, 10.0-b23, Java(TM) SE Runtime Environment, 1.6.0_07-b06
OS: Linux, 2.6.24-21-generic, i386

User Comments: 


Stacktrace: 
java.lang.NumberFormatException: null
Comment 17 esmithbss 2008-09-03 17:06:43 UTC
Created attachment 68972 [details]
stacktrace
Comment 18 _ pcw 2008-09-03 17:14:25 UTC
Very strange.  Ok, I'll check it out again.
Comment 19 Quality Engineering 2008-09-03 17:34:52 UTC
Integrated into 'main-golden', will be available in build *200809031401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/308256ef5420
User: pcw@netbeans.org
Log: #145749 resolved annoying exception when opening properties on web service node and GFV2 is not running
Comment 20 _ pcw 2008-09-03 18:52:44 UTC
Not sure how, but it looks like the patch didn't get integrated into golden before the 9/02 nightly build started.  So
check 9/03 tonight/tomorrow please.
Comment 21 ieising 2008-09-03 20:09:33 UTC
Build: NetBeans IDE Dev (Build 200808311401)
VM: Java HotSpot(TM) Client VM, 11.0-b12, Java(TM) SE Runtime Environment, 1.6.0_10-beta-b25
OS: Windows Vista, 6.0, x86

User Comments: 
I was just clicking in the projects view.

Stacktrace: 
java.lang.NumberFormatException: null
        at java.lang.Integer.parseInt(Integer.java:415)
        at java.lang.Integer.parseInt(Integer.java:497)
        at org.netbeans.modules.j2ee.sun.ide.dm.ServerInstanceDescriptorImpl.getHttpPort(ServerInstanceDescriptorImpl.java:64)
        at org.netbeans.modules.j2ee.deployment.devmodules.api.ServerInstance$Descriptor.getHttpPort(ServerInstance.java:205)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWebServiceURL(JaxWsNode.java:376)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWsdlURL(JaxWsNode.java:615)
Comment 22 ieising 2008-09-03 20:09:34 UTC
Build: NetBeans IDE Dev (Build 200808311401)
VM: Java HotSpot(TM) Client VM, 11.0-b12, Java(TM) SE Runtime Environment, 1.6.0_10-beta-b25
OS: Windows Vista, 6.0, x86

User Comments: 
I was just clicking in the projects view.

Stacktrace: 
java.lang.NumberFormatException: null
        at java.lang.Integer.parseInt(Integer.java:415)
        at java.lang.Integer.parseInt(Integer.java:497)
        at org.netbeans.modules.j2ee.sun.ide.dm.ServerInstanceDescriptorImpl.getHttpPort(ServerInstanceDescriptorImpl.java:64)
        at org.netbeans.modules.j2ee.deployment.devmodules.api.ServerInstance$Descriptor.getHttpPort(ServerInstance.java:205)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWebServiceURL(JaxWsNode.java:376)
        at org.netbeans.modules.websvc.core.jaxws.nodes.JaxWsNode.getWsdlURL(JaxWsNode.java:615)
Comment 23 ieising 2008-09-03 20:09:43 UTC
Created attachment 68981 [details]
stacktrace
Comment 24 ieising 2008-09-03 20:09:51 UTC
Created attachment 68982 [details]
stacktrace
Comment 25 _ pcw 2008-09-06 01:40:44 UTC
This should be fixed in any nightly build since 9/3 (Sept. 3) so I'm closing it again.

Please reopen ONLY if you can reproduce this exception in a build since Sept. 3 and indicate exactly which build you are
running.

Comment 26 Lukas Jungmann 2008-09-17 15:38:00 UTC
v.