On 7/8/11 11:15 PM, glawi wrote:
Hi all, I got the same issue whith Camel 2.7.2.



The FrostByteTransformer.applyTreatmentOnInputData code :
final Incident incident = (Incident)
inputData.getIn().getBody(Map.class).get(DataMapFields.INCIDENT);

                 final Execute request = new Execute();
                 request.setNumber(incident.getNumber());
                 final List<String>  req = new ArrayList<String>();
                 req.add(incident.getNumber());
                 inputData.getOut().setBody(incident.getNumber());
You need to set the request parameter with a Holder.
I just checked the SEI which is generated from your WSDL, the parameter list should be set like this
Object[] parameter = new Object[3];
parameter[0] = incident.getNumber();
parameter[1] = new Holder<String>();
parameter[2] = new Holder<String>();
MessageContentsList request = new MessageContextsList(paramter);
inputData.getOut().getBody(request);

You should get the response from parameter[1] and parameter[2].


And finally the stackTrace following the SOAP request and response traces :
ATTENTION: Interceptor for
{http://www.service-now.com}ServiceNow_frostbyte#{http://www.service-now.com}execute
has thrown exception, unwinding now
java.lang.IndexOutOfBoundsException: Index: 1, Size: 1
        at java.util.ArrayList.RangeCheck(ArrayList.java:547)
        at java.util.ArrayList.get(ArrayList.java:322)
        at
org.apache.cxf.jaxws.interceptors.HolderInInterceptor.handleMessage(HolderInInterceptor.java:67)
        at
org.apache.cxf.phase.PhaseInterceptorChain.doIntercept(PhaseInterceptorChain.java:255)
        at org.apache.cxf.endpoint.ClientImpl.onMessage(ClientImpl.java:737)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream.handleResponseInternal(HTTPConduit.java:2335)
        at
org.apache.cxf.transport.http.HTTPConduit$WrappedOutputStream$1.run(HTTPConduit.java:2198)
        at
org.apache.cxf.workqueue.AutomaticWorkQueueImpl$2.run(AutomaticWorkQueueImpl.java:253)
...




Have you any idea ?

--
View this message in context: 
http://camel.465427.n5.nabble.com/java-lang-IndexOutOfBoundsException-in-cxf-producer-tp468541p4565102.html
Sent from the Camel - Users mailing list archive at Nabble.com.



--
Willem
----------------------------------
FuseSource
Web: http://www.fusesource.com
Blog:    http://willemjiang.blogspot.com (English)
         http://jnn.javaeye.com (Chinese)
Twitter: willemjiang
Weibo: willemjiang

Reply via email to