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 57953 - Classcast exception when when web service result contains complext type with native array member
Summary: Classcast exception when when web service result contains complext type with ...
Status: CLOSED FIXED
Alias: None
Product: webservices
Classification: Unclassified
Component: Code (show other bugs)
Version: 4.x
Hardware: All All
: P1 blocker (vote)
Assignee: _ pcw
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2005-04-16 01:30 UTC by _ pcw
Modified: 2006-03-24 13:00 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
patch diff of fix for this bug (2.27 KB, text/plain)
2005-04-16 01:36 UTC, _ pcw
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ pcw 2005-04-16 01:30:16 UTC
Given: A web service that has an operation that returns a complext type with a
member that is an array of a native type (e.g. int).

Add the service to the registry, bring up the Test Operation dialog for this
operation, enter any necessary parameters, and hit submit.  Before any results
can be displayed, you will get this exception:

Annotation: Exception occurred in Request Processor
java.lang.ClassCastException: [I
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.addResultArrayInstances(TestWebServiceMethodDlg.java:780)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.traverseResultType(TestWebServiceMethodDlg.java:728)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.loadResultTreeTable(TestWebServiceMethodDlg.java:538)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.showResults(TestWebServiceMethodDlg.java:458)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.invokeMethod(TestWebServiceMethodDlg.java:449)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg.access$500(TestWebServiceMethodDlg.java:63)
	at
org.netbeans.modules.websvc.registry.ui.TestWebServiceMethodDlg$4.run(TestWebServiceMethodDlg.java:384)
	at org.openide.util.Task.run(Task.java:189)
	at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:330)
[catch] at
org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:721)

See bug #57896 for a attachment that has a test service with such an operation.
Comment 1 _ pcw 2005-04-16 01:33:55 UTC
Fixed and integrated.

If while testing this patch, other bugs are found, please file them as separate
reports and only reopen this bug if there is an issue with this specific patch.
Comment 2 _ pcw 2005-04-16 01:36:30 UTC
Created attachment 21686 [details]
patch diff of fix for this bug
Comment 3 _ pcw 2005-04-16 01:41:50 UTC
Note to reviewers when deciding whether or not to migrate this patch to 4.1 branch:

In situations where this exception occurs, viewing any part of the result of the
operation is blocked -- not just the array itself.  Because of that, I recommend
including this fix in 4.1.
Comment 4 Lukas Jungmann 2005-04-18 13:16:01 UTC
v. in trunk
Comment 5 Petr Jiricka 2005-04-18 17:19:28 UTC
Showstopper, raising to P1. Ludo, could you please review the diff? Sorry I
didn't find anyone in Prague to do that today. Peter, can you please integrate
into the branch?

Thanks.
Comment 6 _ ludo 2005-04-18 21:11:35 UTC
Code reviewed and OK.
Peter W is on vacation, so I will integrate this in 4.1 branch, as asked by Petr
Jiricka.
Comment 7 _ ludo 2005-04-18 21:16:27 UTC
Fixed in 4.1 branch:
cvs commit -m "Fix for P1
http://www.netbeans.org/issues/show_bug.cgi?id=57953\nClasscast except..." --
TestWebServiceMethodDlg.java (in directory
C:\acvs\40\nb_all\websvc\registry\src\org\netbeans\modules\websvc\registry\ui\)
Checking in TestWebServiceMethodDlg.java;
/cvs/websvc/registry/src/org/netbeans/modules/websvc/registry/ui/Attic/TestWebServiceMethodDlg.java,v
 <--  TestWebServiceMethodDlg.java
new revision: 1.9.2.1; previous revision: 1.9
done
Comment 8 Lukas Jungmann 2005-04-19 11:41:31 UTC
v. in release41 branch