beehive-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "daryoush mehrtash (JIRA)" <beehive-...@incubator.apache.org>
Subject [jira] Updated: (BEEHIVE-848) A serializer is not found for a java bean array that is returned
Date Fri, 15 Jul 2005 21:44:11 GMT
     [ http://issues.apache.org/jira/browse/BEEHIVE-848?page=all ]

daryoush mehrtash updated BEEHIVE-848:
--------------------------------------

    Attachment: JAMES_BLACK_PROBLEM.zip

James,

I don’t have means to run the .NET, I did try out the service you had with Axis unit testing
and it seems to work fine.  The array seems to be deserialized properly and work ok.  Can
you try to duplicate the test with the Junit testing?   Below is the instruction to run the
project, you can also try to modify the test case to duplicate to see if you can duplicate
your issue with JUnit.

The classes I am using are based are the same as your classes,  I just packaged them in the
wsm-blank structure that comes in the beehive samples. 


To try out the code do this:

First build the server side:

cd WEB-INF/src
ant war

Now install the application to your Servlet container  and startup the server

Generate the client side.

ant –f build-client.xml generate.client

This will generate the test cases for you in  WEB-INF/build-client/gen/localhost/ws-test/template/LmsTest1/LmsTestServiceTestCase.java
 you can edit this file to generate new test cases.  I  made the following method to get an
array of 100 values and verified it that the size of the array is correct

    public void test2LmsTestGetItemList() throws Exception {
        localhost.ws_test.template.LmsTest1.LmsTestSoapBindingStub binding;
        try {
            binding = (localhost.ws_test.template.LmsTest1.LmsTestSoapBindingStub)
                          new localhost.ws_test.template.LmsTest1.LmsTestServiceLocator().getLmsTest();
        }
        catch (javax.xml.rpc.ServiceException jre) {
            if(jre.getLinkedCause()!=null)
                jre.getLinkedCause().printStackTrace();
            throw new junit.framework.AssertionFailedError("JAX-RPC ServiceException caught:
" + jre);
        }
        assertNotNull("binding is null", binding);

        // Time out after a minute
        binding.setTimeout(60000);

        // Test operation
        localhost.ws_test.template.LmsTest1.Item[] value = null;
        value = binding.getItemList(new java.lang.String(), new java.lang.String(), 100);
   // Get 100 values
        assertTrue(value.length == 100);                                                 
                                     // Verify the size of arary.  
    }

Now you can build and run the test:


ant –f build-client.xml

When I run this the test passes.  


> A serializer is not found for a java bean array that is returned
> ----------------------------------------------------------------
>
>          Key: BEEHIVE-848
>          URL: http://issues.apache.org/jira/browse/BEEHIVE-848
>      Project: Beehive
>         Type: Bug
>   Components: Web Services (181)
>  Environment: web application is on Tomcat 5.5.9, Solaris 8, JDK1.5 with a nightly build
from June of beehive
>     Reporter: James Black
>     Assignee: daryoush mehrtash
>  Attachments: JAMES_BLACK_PROBLEM.zip, LmsTestClient.rar, ws_test.tar.gz
>
> I get an error about there being no serializer found for a bean that contains a bean
array.  My unit test is in .NET, as that is faster to develop the unit test in. I am including
the .tar.gz file of my project.
> Here is the abbreviated list of my error:
> - Exception: AxisFault
>  faultCode:
> {http://schemas.xmlsoap.org/soap/envelope/}Server.userException
>  faultSubcode:
>  faultString: java.io.IOException: No serializer found for class Item in
> registry org.apache.axis.encoding.TypeMappingDelegate@1d7b662
>  faultActor:
>  faultNode:
>  faultDetail:
> 	{http://xml.apache.org/axis/}stackTrace:java.io.IOException: No
> serializer found for class Item in registry
> org.apache.axis.encoding.TypeMappingDelegate@1d7b662
> 	at
> org.apache.axis.encoding.SerializationContext.serializeActual(SerializationContext.java:1429)
> 	at
> org.apache.axis.encoding.SerializationContext.serialize(SerializationContext.java:914)
> 	at
> org.apache.axis.encoding.SerializationContext.outputMultiRefs(SerializationContext.java:989)
> 	at org.apache.axis.message.SOAPBody.outputImpl(SOAPBody.java:145)
> 	at
> org.apache.axis.message.SOAPEnvelope.outputImpl(SOAPEnvelope.java:477)
> 	at
> org.apache.axis.message.MessageElement.output(MessageElement.java:1208)
> 	at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:315)
> 	at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:269)
> 	at org.apache.axis.SOAPPart.saveChanges(SOAPPart.java:530)
> 	at
> org.apache.axis.attachments.AttachmentsImpl.getAttachmentCount(AttachmentsImpl.java:519)
> 	at org.apache.axis.Message.getContentType(Message.java:475)
> 	at
> org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:775)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> 	at
> org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.apache.beehive.controls.runtime.servlet.ControlFilter.doFilter(ControlFilter.java:131)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> 	at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
> 	at
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
> 	at
> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
> 	at
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
> 	at java.lang.Thread.run(Thread.java:595)
> 	{http://xml.apache.org/axis/}hostname:dante.acomp.usf.edu
> java.io.IOException: No serializer found for class Item in registry
> org.apache.axis.encoding.TypeMappingDelegate@1d7b662
> 	at org.apache.axis.AxisFault.makeFault(AxisFault.java:101)
> 	at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:317)
> 	at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:269)
> 	at org.apache.axis.SOAPPart.saveChanges(SOAPPart.java:530)
> 	at
> org.apache.axis.attachments.AttachmentsImpl.getAttachmentCount(AttachmentsImpl.java:519)
> 	at org.apache.axis.Message.getContentType(Message.java:475)
> 	at
> org.apache.axis.transport.http.AxisServlet.doPost(AxisServlet.java:775)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
> 	at
> org.apache.axis.transport.http.AxisServletBase.service(AxisServletBase.java:327)
> 	at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.apache.beehive.controls.runtime.servlet.ControlFilter.doFilter(ControlFilter.java:131)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
> 	at
> org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
> 	at
> org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
> 	at
> org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
> 	at
> org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
> 	at
> org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
> 	at
> org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
> 	at
> org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
> 	at
> org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
> 	at
> org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
> 	at
> org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
> 	at
> org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
> 	at
> org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
> 	at java.lang.Thread.run(Thread.java:595) Caused by:
> java.io.IOException: No serializer found for class Item in registry
> org.apache.axis.encoding.TypeMappingDelegate@1d7b662
> 	at
> org.apache.axis.encoding.SerializationContext.serializeActual(SerializationContext.java:1429)
> 	at
> org.apache.axis.encoding.SerializationContext.serialize(SerializationContext.java:914)
> 	at
> org.apache.axis.encoding.SerializationContext.outputMultiRefs(SerializationContext.java:989)
> 	at org.apache.axis.message.SOAPBody.outputImpl(SOAPBody.java:145)
> 	at
> org.apache.axis.message.SOAPEnvelope.outputImpl(SOAPEnvelope.java:477)
> 	at
> org.apache.axis.message.MessageElement.output(MessageElement.java:1208)
> 	at org.apache.axis.SOAPPart.writeTo(SOAPPart.java:315)
> 	... 25 more

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators:
   http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see:
   http://www.atlassian.com/software/jira


Mime
View raw message