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 196984 - NullPointerException at org.netbeans.modules.maven.jaxws.WSUtils.addServlet
Summary: NullPointerException at org.netbeans.modules.maven.jaxws.WSUtils.addServlet
Status: RESOLVED INCOMPLETE
Alias: None
Product: webservices
Classification: Unclassified
Component: JAX-WS (show other bugs)
Version: 6.x
Hardware: All All
: P3 normal (vote)
Assignee: Denis Anisimov
URL:
Keywords:
: 186864 (view as bug list)
Depends on:
Blocks:
 
Reported: 2011-03-22 20:36 UTC by airmax9999
Modified: 2011-11-02 15:57 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 177809


Attachments
stacktrace (770 bytes, text/plain)
2011-03-22 20:36 UTC, airmax9999
Details

Note You need to log in before you can comment on or make changes to this bug.
Description airmax9999 2011-03-22 20:36:03 UTC
Build: NetBeans IDE 6.9.1 (Build 201011082200)
VM: Java HotSpot(TM) Client VM, 17.0-b17, Java(TM) SE Runtime Environment, 1.6.0_21-b07
OS: Windows XP

Stacktrace: 
java.lang.NullPointerException
   at org.netbeans.modules.maven.jaxws.WSUtils.addServlet(WSUtils.java:740)
   at org.netbeans.modules.maven.jaxws.WSUtils.addServicesToDD(WSUtils.java:724)
   at org.netbeans.modules.maven.jaxws.WSUtils.checkNonJSR109Entries(WSUtils.java:920)
   at org.netbeans.modules.maven.jaxws.MavenJaxWsSupportProvider.reactOnPomChanges(MavenJaxWsSupportProvider.java:176)
   at org.netbeans.modules.maven.jaxws.MavenJaxWsSupportProvider.access$000(MavenJaxWsSupportProvider.java:71)
   at org.netbeans.modules.maven.jaxws.MavenJaxWsSupportProvider$1.run(MavenJaxWsSupportProvider.java:79)
Comment 1 airmax9999 2011-03-22 20:36:07 UTC
Created attachment 107199 [details]
stacktrace
Comment 2 David Konecny 2011-09-20 21:37:09 UTC
*** Bug 186864 has been marked as a duplicate of this bug. ***
Comment 3 Martin Janicek 2011-11-02 14:11:33 UTC
Reassigning to WS product
Comment 4 Denis Anisimov 2011-11-02 15:57:56 UTC
The NPE appears on the line :
        servlet.setLoadOnStartup(new java.math.BigInteger("1"));

It means null value for servlet var.
The latter variable is created on the previous line :
Servlet servlet = (Servlet)webApp.addBean("Servlet", new String[]{"ServletName","ServletClass"}, 
                new Object[]{servletName, SERVLET_CLASS_NAME}, "ServletName"); 

So the issue is somewhere inside DD module.
I reviewed various implementations of WebApp interface ( the type of webApp var )
and don't see how it can return null value ( there is a possibility for that but
in this case other NPE would have thrown previously ).
Probably I missed some implementations or something else.
So I can't realize the problem without additional information.

Please provide exact steps to reproduce.