You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@ode.apache.org by Håkon Sagehaug <ha...@bccs.uib.no> on 2008/05/26 12:41:56 UTC

Problems with chunking when calling a ws using invoke

Hi

In my bpel process I want to call a web service, where I 've got to set
chunking to false. If i call this service using axis2 generated client
without ode I would do it like this

stub._getServiceClient().getOptions().setProperty(HTTPConstants.CHUNKED,
false);

If I don't do it, I get this error message, which is the same as I get from
ode when calling the ws

org.apache.axis2.AxisFault: Transport error: 411 Error: Length Required
    at
org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:298)
    at
org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:192)
    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
    at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
    at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
    at
org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
    at
org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
    at
org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
    at
org.apache.ode.axis2.ExternalService$1$1.call(ExternalService.java:148)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
    at java.lang.Thread.run(Thread.java:619)

So my question is how I can set the chunking false property in ode when
invoking a ws or some other trick for solving this.

cheers, Håkon


-- 


-- 
Håkon Sagehaug, Software Developer
Parallab, Bergen Center for Computational Science (BCCS)
UNIFOB AS (University of Bergen Research Company)

Re: Problems with chunking when calling a ws using invoke

Posted by Alexis Midon <mi...@intalio.com>.
Hi Hakon,

with the release 1.1 this is not possible unfortunately.
However I'm about to submit a patch that will solve this issue. Track
ODE-295 <https://issues.apache.org/jira/browse/ODE-295>.
A new property file in the deployement unit will allow users to define their
own values for a set of properties, on a service basis.

So you will be able to write something like:
myservice.chunk = false

A new release should be cut soon, I hope I could include this patch in it.
Track the jira issue for updates.

Hope it helps.

Alexis


On Mon, May 26, 2008 at 3:41 AM, Håkon Sagehaug <ha...@bccs.uib.no>
wrote:

> Hi
>
> In my bpel process I want to call a web service, where I 've got to set
> chunking to false. If i call this service using axis2 generated client
> without ode I would do it like this
>
> stub._getServiceClient().getOptions().setProperty(HTTPConstants.CHUNKED,
> false);
>
> If I don't do it, I get this error message, which is the same as I get from
> ode when calling the ws
>
> org.apache.axis2.AxisFault: Transport error: 411 Error: Length Required
>    at
>
> org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:298)
>    at
> org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:192)
>    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
>    at
>
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
>    at
>
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
>    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
>    at
>
> org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
>    at
>
> org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
>    at
> org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
>    at
> org.apache.ode.axis2.ExternalService$1$1.call(ExternalService.java:148)
>    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>    at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
>    at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
>    at java.lang.Thread.run(Thread.java:619)
>
> So my question is how I can set the chunking false property in ode when
> invoking a ws or some other trick for solving this.
>
> cheers, Håkon
>
>
> --
>
>
> --
> Håkon Sagehaug, Software Developer
> Parallab, Bergen Center for Computational Science (BCCS)
> UNIFOB AS (University of Bergen Research Company)
>

Fwd: Problems with chunking when calling a ws using invoke

Posted by Håkon Sagehaug <hs...@gmail.com>.
---------- Forwarded message ----------
From: Håkon Sagehaug <ha...@bccs.uib.no>
Date: 2008/5/26
Subject: Problems with chunking when calling a ws using invoke
To: user@ode.apache.org


Hi

In my bpel process I want to call a web service, where I 've got to set
chunking to false. If i call this service using axis2 generated client
without ode I would do it like this

stub._getServiceClient().getOptions().setProperty(HTTPConstants.CHUNKED,
false);

If I don't do it, I get this error message, which is the same as I get from
ode when calling the ws

org.apache.axis2.AxisFault: Transport error: 411 Error: Length Required
    at
org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:298)
    at
org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:192)
    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
    at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
    at
org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
    at
org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
    at
org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
    at
org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
    at
org.apache.ode.axis2.ExternalService$1$1.call(ExternalService.java:148)
    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
    at
java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
    at java.lang.Thread.run(Thread.java:619)

So my question is how I can set the chunking false property in ode when
invoking a ws or some other trick for solving this.

cheers, Håkon


-- 


-- 
Håkon Sagehaug, Software Developer
Parallab, Bergen Center for Computational Science (BCCS)
UNIFOB AS (University of Bergen Research Company)



-- 
Håkon Sagehaug, Software Developer
Parallab, Bergen Center for Computational Science (BCCS)
UNIFOB AS (University of Bergen Research Company)

Re: Problems with chunking when calling a ws using invoke

Posted by Håkon Sagehaug <hs...@gmail.com>.
Hi

That worked, I thought I'd tried that before,but maybe I did not do it
correct. I would be nice that have the config file feature you mentioned in
the previous mail, looking forward to it

cheers, Håkon

2008/5/27 Alex Boisvert <bo...@intalio.com>:

> Alternatively, you can edit the axis2.xml file which is part of the Ode
> distribution and set it to use HTTP 1.0 (no chunking):
>
> <transportSender name="http"
> class="org.apache.axis2.transport.http.CommonsHTTPTransportSender">
>  <parameter name="PROTOCOL" locked="false">HTTP/1.0</parameter>
> </transportSender>
>
> Note that this set HTTP 1.0 for _all_ external services, instead of
> specifically for a given service.
>
> alex
>
> On Mon, May 26, 2008 at 3:41 AM, Håkon Sagehaug <
> hakon.sagehaug@bccs.uib.no>
> wrote:
>
> > Hi
> >
> > In my bpel process I want to call a web service, where I 've got to set
> > chunking to false. If i call this service using axis2 generated client
> > without ode I would do it like this
> >
> > stub._getServiceClient().getOptions().setProperty(HTTPConstants.CHUNKED,
> > false);
> >
> > If I don't do it, I get this error message, which is the same as I get
> from
> > ode when calling the ws
> >
> > org.apache.axis2.AxisFault: Transport error: 411 Error: Length Required
> >    at
> >
> >
> org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:298)
> >    at
> >
> org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:192)
> >    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
> >    at
> >
> >
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
> >    at
> >
> >
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
> >    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
> >    at
> >
> >
> org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
> >    at
> >
> >
> org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
> >    at
> > org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
> >    at
> > org.apache.ode.axis2.ExternalService$1$1.call(ExternalService.java:148)
> >    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
> >    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
> >    at
> >
> >
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
> >    at
> >
> >
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
> >    at java.lang.Thread.run(Thread.java:619)
> >
> > So my question is how I can set the chunking false property in ode when
> > invoking a ws or some other trick for solving this.
> >
> > cheers, Håkon
> >
> >
> > --
> >
> >
> > --
> > Håkon Sagehaug, Software Developer
> > Parallab, Bergen Center for Computational Science (BCCS)
> > UNIFOB AS (University of Bergen Research Company)
> >
>



-- 
Håkon Sagehaug, Software Developer
Parallab, Bergen Center for Computational Science (BCCS)
UNIFOB AS (University of Bergen Research Company)

Re: Problems with chunking when calling a ws using invoke

Posted by Alex Boisvert <bo...@intalio.com>.
Alternatively, you can edit the axis2.xml file which is part of the Ode
distribution and set it to use HTTP 1.0 (no chunking):

<transportSender name="http"
class="org.apache.axis2.transport.http.CommonsHTTPTransportSender">
  <parameter name="PROTOCOL" locked="false">HTTP/1.0</parameter>
</transportSender>

Note that this set HTTP 1.0 for _all_ external services, instead of
specifically for a given service.

alex

On Mon, May 26, 2008 at 3:41 AM, Håkon Sagehaug <ha...@bccs.uib.no>
wrote:

> Hi
>
> In my bpel process I want to call a web service, where I 've got to set
> chunking to false. If i call this service using axis2 generated client
> without ode I would do it like this
>
> stub._getServiceClient().getOptions().setProperty(HTTPConstants.CHUNKED,
> false);
>
> If I don't do it, I get this error message, which is the same as I get from
> ode when calling the ws
>
> org.apache.axis2.AxisFault: Transport error: 411 Error: Length Required
>    at
>
> org.apache.axis2.transport.http.HTTPSender.handleResponse(HTTPSender.java:298)
>    at
> org.apache.axis2.transport.http.HTTPSender.sendViaPost(HTTPSender.java:192)
>    at org.apache.axis2.transport.http.HTTPSender.send(HTTPSender.java:77)
>    at
>
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.writeMessageWithCommons(CommonsHTTPTransportSender.java:327)
>    at
>
> org.apache.axis2.transport.http.CommonsHTTPTransportSender.invoke(CommonsHTTPTransportSender.java:206)
>    at org.apache.axis2.engine.AxisEngine.send(AxisEngine.java:396)
>    at
>
> org.apache.axis2.description.OutInAxisOperationClient.send(OutInAxisOperation.java:374)
>    at
>
> org.apache.axis2.description.OutInAxisOperationClient.executeImpl(OutInAxisOperation.java:211)
>    at
> org.apache.axis2.client.OperationClient.execute(OperationClient.java:163)
>    at
> org.apache.ode.axis2.ExternalService$1$1.call(ExternalService.java:148)
>    at java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303)
>    at java.util.concurrent.FutureTask.run(FutureTask.java:138)
>    at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885)
>    at
>
> java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907)
>    at java.lang.Thread.run(Thread.java:619)
>
> So my question is how I can set the chunking false property in ode when
> invoking a ws or some other trick for solving this.
>
> cheers, Håkon
>
>
> --
>
>
> --
> Håkon Sagehaug, Software Developer
> Parallab, Bergen Center for Computational Science (BCCS)
> UNIFOB AS (University of Bergen Research Company)
>