1

I'm trying to force the WSO2 to set the http version to 1.0 because the client of a service requires the Content-Length property. I configured the following properties in the outSequence, before the <send/>:

<property name="FORCE_HTTP_1.0" value="true" scope="axis2"/>
<property name="DISABLE_CHUNKING" value="true" scope="axis2"/>

but it doesn't works! The response header:

HTTP/1.0 200 OK
userAgent: Synapse-PT-HttpComponents-NIO
Host: localhost:8280
SOAPAction: "sendMessage"
Accept-Encoding: gzip,deflate
Content-Type: text/xml; charset=UTF-8
Server: WSO2-PassThrough-HTTP
Date: Thu, 13 Mar 2014 21:55:25 GMT
Connection: Close

I'm using ESB 4.6.0 and SoapUI to call the service.
Why the Content-Length doesn't appears? What's wrong?

Community
  • 1
  • 1
elias
  • 15,010
  • 4
  • 40
  • 65

1 Answers1

2

This is a bug in ESB and we fixed it recently.

https://wso2.org/jira/browse/ESBJAVA-2985

The properties you mentioned are not working in outSequence path.

The fix should be available in next release.

The patch for Synapse transport is also attached in ESBJAVA-2985 and you may patch the Synapse version in your WSO2 ESB.

Community
  • 1
  • 1
Isuru Perera
  • 1,905
  • 1
  • 11
  • 23
  • The source of the version 4.6.0 is not available for download. – elias Mar 14 '14 at 13:16
  • All WSO2 code is open source and available at SVN https://svn.wso2.org/repos/wso2/carbon/. It's just the link to specific tag is missing in the web site. Do you have intention of patching? If so, I can give you instructions. – Isuru Perera Mar 14 '14 at 16:32
  • Any reasons for using ESB 4.6.0? Is it possible to use ESB 4.8.1? – Isuru Perera Mar 14 '14 at 16:35
  • Thanks for answer Isuru. There's some tutorial? I would appreciate if you help me to apply this patch. – elias Mar 14 '14 at 17:31
  • And I'm using 4.6.0 because it's the version currently approved for run here on the company. – elias Mar 14 '14 at 17:31
  • The synapse version used in ESB 4.6.0 is https://svn.wso2.org/repos/wso2/carbon/platform/branches/4.0.0/dependencies/synapse/2.1.1-wso2v2/. So we need to checkout this and create the patch – Isuru Perera Mar 17 '14 at 07:32
  • Where I should execute the `mvn install`? And what is the required maven version? – elias Mar 17 '14 at 15:09
  • You should be able to build from the path I gave. Please use Maven 3.0.5 and Oracle JDK 1.6. – Isuru Perera Mar 17 '14 at 16:53
  • This patch causes compiler errors. The class `MessageProcessorSelector` was not found. – elias Mar 17 '14 at 17:23
  • I didn't get much time to look at the code. There can be lot of changes between ESB 4.6.0 Synapse and ESB 4.8.0 Synapse. We have to carefully check and patch. – Isuru Perera Mar 17 '14 at 17:35
  • That class was added to axis2 in the version 1.6.1-wso2v8. The pom.xml references the 1.6.1-wso2v7. – elias Mar 17 '14 at 17:44
  • Finally worked! But I had to change the files manually following the patch logic. Thanks Isuru. – elias Mar 17 '14 at 21:49
  • Hi, I am currently using WSO2 and because of it using HTTP/2 by default on token timeout my stream is not closing. Can you please help me out here and let me know how can I ensure WSO2 does not using HTTP/2. Note I am only using the api manager and not the ESB – prashant Jan 16 '20 at 08:42