steeltomato/jmeter-amf — Issue #22: Exception in log after record actions with AMF Proxy
Author: lfidnl
Created: 2012-01-27 09:03:08+00:00
State: open

Hi! Thanks for plugin. I have problem with record actions with AMF Proxy. After goto my tested applicatin I have exception in log:

```
2012/01/27 11:24:02 ERROR - jmeter.protocol.amf.util.AmfXmlConverter: An exception was encountered while deserializing response. java.lang.IndexOutOfBoundsException: Index: 58, Size: 2
at java.util.ArrayList.RangeCheck(Unknown Source)
at java.util.ArrayList.get(Unknown Source)
at flex.messaging.io.amf.Amf3Input.getStringReference(Amf3Input.java:718)
at flex.messaging.io.amf.Amf3Input.readString(Amf3Input.java:244)
at flex.messaging.io.amf.Amf3Input.readTraits(Amf3Input.java:548)
at flex.messaging.io.amf.Amf3Input.readScriptObject(Amf3Input.java:402)
at flex.messaging.io.amf.Amf3Input.readObjectValue(Amf3Input.java:152)
at flex.messaging.io.amf.Amf3Input.readObject(Amf3Input.java:130)
at flex.messaging.io.amf.Amf0Input.readObjectValue(Amf0Input.java:123)
at flex.messaging.io.amf.Amf0Input.readArrayValue(Amf0Input.java:359)
at flex.messaging.io.amf.Amf0Input.readObjectValue(Amf0Input.java:127)
at flex.messaging.io.amf.Amf0Input.readObject(Amf0Input.java:94)
at flex.messaging.io.amf.AmfMessageDeserializer.readObject(AmfMessageDeserializer.java:227)
at flex.messaging.io.amf.AmfMessageDeserializer.readBody(AmfMessageDeserializer.java:206)
at flex.messaging.io.amf.AmfMessageDeserializer.readMessage(AmfMessageDeserializer.java:126)
at org.apache.jmeter.protocol.amf.util.AmfXmlConverter.convertAmfMessageToXml(AmfXmlConverter.java:168)
at org.apache.jmeter.protocol.amf.util.AmfXmlConverter.convertAmfMessageToXml(AmfXmlConverter.java:140)
at org.apache.jmeter.protocol.amf.proxy.AmfRequestHdr.populateSampler(AmfRequestHdr.java:463)
at org.apache.jmeter.protocol.amf.proxy.AmfRequestHdr.getSampler(AmfRequestHdr.java:281)
at org.apache.jmeter.protocol.amf.proxy.AmfProxy.run(AmfProxy.java:229)
```

and XML editor has only following lines:

```

3

null
/1

```

I tried to run jmeter with -Dfile.encoding=UTF-8 but exception still reproduce

My application use BlazeDS 3.0.0.544 and if I include the same version of BlazeDS to lib/ext I have following issue:

```
2012/01/27 11:32:42 ERROR - jmeter.JMeter: Uncaught exception: java.lang.NoSuchFieldError: createASObjectForMissingType
at org.apache.jmeter.protocol.amf.util.AmfXmlConverter.convertAmfMessageToXml(AmfXmlConverter.java:156)
at org.apache.jmeter.protocol.amf.util.AmfXmlConverter.convertAmfMessageToXml(AmfXmlConverter.java:140)
at org.apache.jmeter.protocol.amf.proxy.AmfRequestHdr.populateSampler(AmfRequestHdr.java:463)
at org.apache.jmeter.protocol.amf.proxy.AmfRequestHdr.getSampler(AmfRequestHdr.java:281)
at org.apache.jmeter.protocol.amf.proxy.AmfProxy.run(AmfProxy.java:229)
```

I've tried to replace BlazeDS 3 with BlazeDS 4 in application and in JMeter lib/ext but it didn't help

Charles successfuly catch and parse the request/response. [Here is sceenshot](http://dl.dropbox.com/u/2440747/charles.png) (sorry I don't know how to copy/paste structure of request :) )
And if it will be helpful [here is the binary POST form JMeter](http://dl.dropbox.com/u/2440747/POST4140278549062874828.binary)