Please use the Apache issue tracking system for new NetBeans issues (https://issues.apache.org/jira/projects/NETBEANS0/issues) !!
Bug 167352 - NullPointerException at org.netbeans.modules.j2ee.sun.ws7.ui.WS70ConnectionTabVisualPanel.isValid
NullPointerException at org.netbeans.modules.j2ee.sun.ws7.ui.WS70ConnectionTa...
Status: RESOLVED FIXED
Product: serverplugins
Classification: Unclassified
Component: WebServer 7
6.x
All All
: P2 (vote)
: TBD
Assigned To: kishore320
iwsprem
http://statistics.netbeans.org/except...
EXCEPTIONS_REPORT
:
Depends on:
Blocks: 154624
  Show dependency treegraph
 
Reported: 2009-06-19 07:45 UTC by Petr Jiricka
Modified: 2010-03-25 03:30 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
:


Attachments
An attempt at a patch (2.23 KB, text/plain)
2009-06-19 08:22 UTC, Petr Jiricka
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Petr Jiricka 2009-06-19 07:45:11 UTC
Build: NetBeans IDE 6.5.1 (Build 200903060201)
VM: Java HotSpot(TM) Client VM, 11.3-b02, Java(TM) SE Runtime Environment, 1.6.0_13-b03
OS: Windows XP, 5.1, x86
User comments: 
STACKTRACE: (first 10 lines)
java.lang.NullPointerException
        at org.netbeans.modules.j2ee.sun.ws7.ui.WS70ConnectionTabVisualPanel.isValid(WS70ConnectionTabVisualPanel.java:233)
        at java.awt.Component.invalidateIfValid(Component.java:2740)
        at java.awt.Component.setLocale(Component.java:1810)
        at javax.swing.JComponent.<init>(JComponent.java:595)
        at javax.swing.JPanel.<init>(JPanel.java:65)
        at javax.swing.JPanel.<init>(JPanel.java:92)
        at javax.swing.JPanel.<init>(JPanel.java:100)
        at org.netbeans.modules.j2ee.sun.ws7.ui.WS70ConnectionTabVisualPanel.<init>(WS70ConnectionTabVisualPanel.java:58)
        at org.netbeans.modules.j2ee.sun.ws7.ui.WS70Customizer.initComponents(WS70Customizer.java:108)
        at org.netbeans.modules.j2ee.sun.ws7.ui.WS70Customizer.<init>(WS70Customizer.java:85)
Comment 1 Petr Jiricka 2009-06-19 08:21:33 UTC
This is related to the Swing changes in JDK 6 update 12, see umbrella issue 154624. This should definitely be fixed for
NB 6.7. I am attaching an attempt for a patch - untested yet (I could not find a way to install Sun webserver on my Mac,
so could not test).
Comment 2 Petr Jiricka 2009-06-19 08:22:49 UTC
Created attachment 83789 [details]
An attempt at a patch
Comment 3 kcpraveen 2010-03-23 14:20:52 UTC
Many reports of this exception:
http://statistics.netbeans.org/analytics/exception.do?id=319067
Comment 4 kishore320 2010-03-24 08:35:39 UTC
changeset:   16114:62a43bd96ebb
tag:         tip
user:        Nagakishore Sidde <kishore320@netbeans.org>
date:        Tue Feb 09 17:30:14 2010 +0530
files:     j2ee.sun.ws7/src/org/netbeans/modules/j2ee/sun/ws7/ui/WS70ConnectionTabVisualPanel.java
description: No need to override the 'isValid()' of awt component.So removing it

reviwed by : Isvaran Krishnamurthy <ikrishna@netbeans.org>
Comment 5 _ tboudreau 2010-03-24 16:53:00 UTC
What repository is this fix in?  I cannot find it in http://hg.netbeans.org/web-main/ or http://hg.netbeans.org/main/

If you simply removed the override of isValid(), the fix is probably not correct.  The bug is that a GUI component is implementing WizardDescriptor.Panel.

Both java.awt.Component and WizardDescriptor.Panel have contradictory isValid() methods - WizardDescriptor.Panel must not be implemented on a component subclass, period.

The correct fix is to separate the implementation of WizardDescriptor.Panel into a separate class.  If you just deleted the override of isValid(), then the wizard will now decide if the next button should be enabled or not based on whether *the panel needs to have its layout manager lay it out or not*!  That is not what you want.

If you did move the implementation to a separate class, great.  If not, please reopen this bug and fix correctly.
Comment 6 kishore320 2010-03-25 03:30:51 UTC
The changes are in under http://hg.netbeans.org/main/contrib/j2ee.sun.ws7

WizardDescriptor.Panel method implementation does exists in a WS70AddServerChoicePanel class. The isValid() that i removed simply checks for the non null value of admin user text, which we are doing other wise.


By use of this website, you agree to the NetBeans Policies and Terms of Use. © 2014, Oracle Corporation and/or its affiliates. Sponsored by Oracle logo