Trouble with POST without Content-Type HTTPBC

2 messages Options
Embed this post
Permalink
Anatoliy Medvedchuk

Trouble with POST without Content-Type HTTPBC

Reply Threaded More More options
Print post
Permalink
Good day all

I need to use HTTP BC and Bpel to serve post requests. I created simple bipel project that just log post message and reply with them back. it works fine while header parameter Content-Type is present in request (even if it is empty). But without this parameter jbi message part becames empty.

So when I send next request:

POST http://localhost:9080/httpPostService/httpPostPort HTTP/1.1testProject.rar
User-Agent: Jakarta Commons-HttpClient/3.1
Content-Length: 44
Content-Type:

<test><subtest>bla-bla-blal</subtest></test>


there is server logs:

[#|2009-10-21T10:13:03.573+0300|FINE|sun-appserver9.1|com.sun.jbi.httpsoapbc.XmlPostNormalizer|_ThreadID=149;_ThreadName=HTTPBC-JAXWS-Engine-4;ClassName=com.sun.jbi.httpsoapbc.util.DebugLog;MethodName=debugLog;_RequestID=9b8dc5ff-e205-4761-8336-f95dfb9a8a5e;|Normalized message:
<?xml version="1.0" encoding="UTF-8"?><jbi:message xmlns:msgns="http://j2ee.netbeans.org/wsdl/testHttpPost/httpPost" name="input1" type="msgns:httpPostOperationRequest" version="1.0" xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper"><jbi:part><test><subtest>bla-bla-blal</subtest></test></jbi:part></jbi:message>|#]

[#|2009-10-21T10:13:03.573+0300|INFO|sun-appserver9.1|com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager|_ThreadID=146;_ThreadName=sun-bpel-engine-thread-3;Process Instance Id=39e4f34:12471ba7c4b:-6e69;Service Assembly Name=testHttpPostCa;Activity Name=Receive1;BPEL Process Name=testHttpPost;|received request = <test><subtest>bla-bla-blal</subtest></test>|#]

But when i send this post, I receive empty response:

POST http://localhost:9080/httpPostService/httpPostPort HTTP/1.1
User-Agent: Jakarta Commons-HttpClient/3.1
Content-Length: 44

<test><subtest>bla-bla-blal</subtest></test>


[#|2009-10-21T10:13:20.745+0300|FINE|sun-appserver9.1|com.sun.jbi.httpsoapbc.XmlPostNormalizer|_ThreadID=150;_ThreadName=HTTPBC-JAXWS-Engine-1;ClassName=com.sun.jbi.httpsoapbc.util.DebugLog;MethodName=debugLog;_RequestID=fd8613c4-afdb-490e-828c-9e6b64c68300;|Normalized message:
<?xml version="1.0" encoding="UTF-8"?><jbi:message xmlns:msgns="http://j2ee.netbeans.org/wsdl/testHttpPost/httpPost" name="input1" type="msgns:httpPostOperationRequest" version="1.0" xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper"><jbi:part/></jbi:message>|#]

[#|2009-10-21T10:13:20.745+0300|INFO|sun-appserver9.1|com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager|_ThreadID=151;_ThreadName=sun-bpel-engine-thread-2;Process Instance Id=39e4f34:12471ba7c4b:-6e68;Service Assembly Name=testHttpPostCa;Activity Name=Receive1;BPEL Process Name=testHttpPost;|received request = |#]


In attachment you can find my test project.

So, can anyone help me to receive post without content-type parameter? may be there are some settings?

Thanks.
SherryWeng

Re: Trouble with POST without Content-Type HTTPBC

Reply Threaded More More options
Print post
Permalink
Hmm, can't tell right away what might be the problem. I've logged a
ticket to track this:
https://open-esb.dev.java.net/issues/show_bug.cgi?id=2377
Will keep you posted.

Regards
--Sherry

Anatoliy Medvedchuk wrote:

> Good day all
>
> I need to use HTTP BC and Bpel to serve post requests. I created simple
> bipel project that just log post message and reply with them back. it works
> fine while header parameter Content-Type is present in request (even if it
> is empty). But without this parameter jbi message part becames empty.
>
> So when I send next request:
>
> POST http://localhost:9080/httpPostService/httpPostPort HTTP/1.1
> http://n2.nabble.com/file/n3863780/testProject.rar testProject.rar
> User-Agent: Jakarta Commons-HttpClient/3.1
> Content-Length: 44
> Content-Type:
>
> <test><subtest>bla-bla-blal</subtest></test>
>
> there is server logs:
>
> [#|2009-10-21T10:13:03.573+0300|FINE|sun-appserver9.1|com.sun.jbi.httpsoapbc.XmlPostNormalizer|_ThreadID=149;_ThreadName=HTTPBC-JAXWS-Engine-4;ClassName=com.sun.jbi.httpsoapbc.util.DebugLog;MethodName=debugLog;_RequestID=9b8dc5ff-e205-4761-8336-f95dfb9a8a5e;|Normalized
> message:
> <?xml version="1.0" encoding="UTF-8"?><jbi:message
> xmlns:msgns="http://j2ee.netbeans.org/wsdl/testHttpPost/httpPost"
> name="input1" type="msgns:httpPostOperationRequest" version="1.0"
> xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper"><jbi:part><test><subtest>bla-bla-blal</subtest></test></jbi:part></jbi:message>|#]
>
> [#|2009-10-21T10:13:03.573+0300|INFO|sun-appserver9.1|com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager|_ThreadID=146;_ThreadName=sun-bpel-engine-thread-3;Process
> Instance Id=39e4f34:12471ba7c4b:-6e69;Service Assembly
> Name=testHttpPostCa;Activity Name=Receive1;BPEL Process
> Name=testHttpPost;|received request =
> <test><subtest>bla-bla-blal</subtest></test>|#]
>
> But when i send this post, I receive empty response:
>
> POST http://localhost:9080/httpPostService/httpPostPort HTTP/1.1
> User-Agent: Jakarta Commons-HttpClient/3.1
> Content-Length: 44
>
> <test><subtest>bla-bla-blal</subtest></test>
>
>
> [#|2009-10-21T10:13:20.745+0300|FINE|sun-appserver9.1|com.sun.jbi.httpsoapbc.XmlPostNormalizer|_ThreadID=150;_ThreadName=HTTPBC-JAXWS-Engine-1;ClassName=com.sun.jbi.httpsoapbc.util.DebugLog;MethodName=debugLog;_RequestID=fd8613c4-afdb-490e-828c-9e6b64c68300;|Normalized
> message:
> <?xml version="1.0" encoding="UTF-8"?><jbi:message
> xmlns:msgns="http://j2ee.netbeans.org/wsdl/testHttpPost/httpPost"
> name="input1" type="msgns:httpPostOperationRequest" version="1.0"
> xmlns:jbi="http://java.sun.com/xml/ns/jbi/wsdl-11-wrapper"><jbi:part/></jbi:message>|#]
>
> [#|2009-10-21T10:13:20.745+0300|INFO|sun-appserver9.1|com.sun.jbi.engine.bpel.core.bpel.trace.BPELTraceManager|_ThreadID=151;_ThreadName=sun-bpel-engine-thread-2;Process
> Instance Id=39e4f34:12471ba7c4b:-6e68;Service Assembly
> Name=testHttpPostCa;Activity Name=Receive1;BPEL Process
> Name=testHttpPost;|received request = |#]
>
>
> In attachment you can find my test project.
>
> So, can anyone help me to receive post without content-type parameter? may
> be there are some settings?
>
> Thanks.
>
>  

---------------------------------------------------------------------
To unsubscribe, e-mail: [hidden email]
For additional commands, e-mail: [hidden email]