Uploaded image for project: 'Axis'
  1. Axis
  2. AXIS-1986

java.lang.IllegalArgumentException: argument type mismatch When deserializing byte[]

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Blocker
    • Resolution: Fixed
    • 1.2RC3
    • None
    • None
    •    Web Servers: Tomcat 4.1.31, 5.0.28, 5.5.4
      Axis Versions: Not present in Axis 1.1. Occurs in Axis 1.2 all releases up to 1.2.1.
      Java: 1.4.2_04
      Operating Systems: Present on Windows XP and Solaris 5.8

    Description

      We make a product for running Oracle stored procedures and SQL statements that is designed to work with Axis. This involves creating data structures that contain byte[] arrays. One of our regression tests involves the following method:

      public axis12bug.plsql.RawProcReturn servicePlsqlRawProc
      (byte[] paramInParam
      ,byte[] paramInOutParam) throws DAOFactoryServiceException

      RawProcReturn looks like this:

      public class RawProcReturn
      {
      public byte[] paramOutParam = null;
      public byte[] paramInOutParam = null;

      }

      This failing against Axis 1.2.1 but not Axis 1.1 because it throws the following error:

      • Could not convert java.lang.Byte to bean field 'paramOutParam', type [B
      • Exception:
        java.lang.IllegalArgumentException: argument type mismatch
        at org.apache.axis.encoding.ser.BeanPropertyTarget.set(BeanPropertyTarget.java:146)
        at org.apache.axis.encoding.DeserializerImpl.valueComplete(DeserializerImpl.java:249)
        at org.apache.axis.encoding.DeserializerImpl.endElement(DeserializerImpl.java:509)
        at org.apache.axis.encoding.DeserializationContext.endElement(DeserializationContext.java:1087)
        at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:171)
        at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1140)
        at org.apache.axis.encoding.DeserializerImpl.startElement(DeserializerImpl.java:369)
        at org.apache.axis.encoding.ser.BeanDeserializer.startElement(BeanDeserializer.java:154)
        at org.apache.axis.encoding.DeserializationContext.startElement(DeserializationContext.java:1048)
        at org.apache.axis.message.SAX2EventRecorder.replay(SAX2EventRecorder.java:165)
        at org.apache.axis.message.MessageElement.publishToHandler(MessageElement.java:1140)
        at org.apache.axis.message.RPCElement.deserialize(RPCElement.java:236)
        at org.apache.axis.message.RPCElement.getParams(RPCElement.java:384)
        at org.apache.axis.client.Call.invoke(Call.java:2448)
        at org.apache.axis.client.Call.invoke(Call.java:2347)
        at org.apache.axis.client.Call.invoke(Call.java:1804)
        at axis12bug.TESTAXIS_12BUG1SoapBindingStub.servicePlsqlRawProc(TESTAXIS_12BUG1SoapBindingStub.java:235)
        at axis12bug.RunTest.main(RunTest.java:42)
        ; nested exception is:
        java.lang.IllegalArgumentException: argument type mismatch

      This bug may be a clone of Axis-1985.

      We have zipped a test case and uploaded it to:

      http://www.orindasoft.com/public/friends/smallarraysbug.zip

      We regard this as a blocker because:

      1. This works in Axis 1.1.
      2. The ability to work with objects that have byte[] arrays is fundamental to anyone working with BLOB or CLOB data.

      Attachments

        1. smallarraysbug.zip
          43 kB
          Davanum Srinivas

        Issue Links

          Activity

            People

              Unassigned Unassigned
              drolfe David Rolfe
              Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

                Created:
                Updated:
                Resolved: