cancel
Showing results for 
Search instead for 
Did you mean: 

Error log on http request from business connector (BC)

laurent_touillaud
Contributor
0 Kudos

Hi all,

We are sending http requests from our business connector to one client but the messages keep having log errors :

server.log details :

003C24 [B2BCORE.0064.0014] Opening Socket https://www.qab2b.xxx.com:443/invoke/wm.b2b.cxml:receiveCXML proxy=10.28.38.27:80

003C25 [B2BCORE.0038.0002] --> CONNECT www.qab2b.xxx.com:443 HTTP/1.0

003C26 [B2BCORE.0038.0002] --> User-Agent: Mozilla/4.0 [en] (WinNT; I)

003C27 [B2BCORE.0038.0002] --> Accept: image/gif, /

003C28 [B2BCORE.0038.0002] --> Host: www.qab2b.xxx.com:443

003C29 [B2BCORE.0038.0002] --> Proxy-Authorization: Basic YWJ1c2luZXNzY29ubmVjdG9yOmFidXNpbjA0

003C2A [B2BCORE.0038.0002] --> Authorization: Basic U0ZSQ2VnZXRlbDoyMDA3KkVBSV9TRlI=

003C2B [B2BCORE.0038.0002] > Content-type: multipart/mixed; boundary="--=_Part_0_1941981.1219399983635"

003C2C [B2BCORE.0038.0002] --> Message-ID: <7159395.1219399983666.JavaMail.SYSTEM@sw0030>

003C2D [B2BCORE.0038.0002] --> Mime-Version: 1.0

003C2E [B2BCORE.0040.0001] HTTP/1.1 200

003C2F [B2BCORE.0064.0017] Proxy Header <--Connection established

003C30 [B2BCORE.0038.0002] --> POST /invoke/wm.b2b.cxml:receiveCXML HTTP/1.0

003C31 [B2BCORE.0038.0002] --> User-Agent: Mozilla/4.0 [en] (WinNT; I)

003C32 [B2BCORE.0038.0002] --> Accept: image/gif, /

003C33 [B2BCORE.0038.0002] --> Host: www.qab2b.xxx.com:443

003C34 [B2BCORE.0038.0002] --> Proxy-Authorization: Basic YWJ1c2luZXNzY29ubmVjdG9yOmFidXNpbjA0

003C35 [B2BCORE.0038.0002] --> Authorization: Basic U0ZSQ2VnZXRlbDoyMDA3KkVBSV9TRlI=

003C36 [B2BCORE.0038.0002] > Content-type: multipart/mixed; boundary="--=_Part_0_1941981.1219399983635"

003C37 [B2BCORE.0038.0002] --> Message-ID: <7159395.1219399983666.JavaMail.SYSTEM@sw0030>

003C38 [B2BCORE.0038.0002] --> Mime-Version: 1.0

003C39 [B2BCORE.0038.0002] --> Content-Length: 188225

003C3A [B2BCORE.0040.0001] HTTP/1.0 200

003C3B [B2BCORE.0041.0001] ssnid=86087kPxFCsECcmXU5DHUAInKY9mEIIU-9355222; path=/;

003C3C [B2BCORE.0038.0002] <-- Set-Cookie: ssnid=86087kPxFCsECcmXU5DHUAInKY9mEIIU-9355222; path=/;

003C3D [B2BCORE.0038.0002] <-- Content-Type: multipart/mixed; boundary="----=_Part_0_1941981.1219399983635"

003C3E [B2BCORE.0038.0002] <-- Connection: Close

003C3F [B2BCORE.0038.0002] <-- Content-Length: 0

003C40 [B2BCORE.0049.0008] Sequence : index=8 depth=3

003C41 [B2BCORE.0049.0008] Sequence : index=6 depth=2

003C42 [B2BCORE.0049.0008] Sequence : index=1 depth=3

003C43 [B2BCORE.0049.0005] Invoke : index=1 depth=4

003C44 [B2BCORE.0049.0008] Sequence : index=2 depth=3

003C45 [B2BCORE.0049.0005] Invoke : index=1 depth=4

003C46 [B2BCORE.0049.0008] Sequence : index=3 depth=3

003C47 [B2BCORE.0049.0005] Invoke : index=1 depth=4

003C48 [B2BSERV.0048.9999] Array index out of range: -1

003C49 [B2BCORE.0049.0008] Sequence : index=4 depth=3

003C4A [B2BCORE.0050.0004] Copy failed: (Simple) No source data available: to=/returnedStatusCode(0), from=/returnHttp(0)/cXML(0)/Response(0)/Status(0)/@code(0)

003C4B [B2BCORE.0050.0004] Copy failed: (Simple) No source data available: to=/returnedMessage(0), from=/returnHttp(0)/cXML(0)/Response(0)/Status(0)/*body(0)

003C4C [B2BCORE.0050.0004] Copy failed: (Simple) No source data available: to=/returnedText(0), from=/returnHttp(0)/cXML(0)/Response(0)/Status(0)/@text(0)

003C4D [B2BCORE.0049.0008] Sequence : index=5 depth=3

003C4E [B2BCORE.0049.0008] Sequence : index=6 depth=3

003C4F [B2BCORE.0049.0008] Sequence : index=7 depth=2

003C50 [B2BCORE.0049.0008] Sequence : index=2 depth=1

003C51 [B2BSERV.0056.0003] Unable to send mail. Illegal address

error java log on server>logs>error:

2008-08-22 12:16:33 CEST java.lang.ArrayIndexOutOfBoundsException: Array index out of range: -1

at com.wm.util.List.elementAt(List.java:101)

at com.wm.lang.xml.token.BlockInputBuffer.getChar(BlockInputBuffer.java:59)

at com.wm.lang.xml.TextNode.appendSqueezedText(TextNode.java:178)

at com.wm.lang.xml.ElementNode.appendSqueezedText(ElementNode.java:333)

at com.wm.lang.xml.ElementNode.getTextOfChildren(ElementNode.java:309)

at com.wm.lang.xml.Document.getTextOfChildren(Document.java:542)

at com.wm.app.b2b.services.DocumentToRecordService.recursiveCollect(DocumentToRecordService.java:661)

at com.wm.app.b2b.services.DocumentToRecordService.bind(DocumentToRecordService.java:356)

at pub.web.documentToRecord(web.java:667)

at java.lang.reflect.Method.invoke(Native Method)

at com.wm.app.b2b.server.JavaService.baseInvoke(JavaService.java:281)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)

at com.wm.app.b2b.server.BaseService.invoke(BaseService.java:140)

at com.wm.lang.flow.FlowInvoke.invoke(FlowInvoke.java:292)

at com.wm.lang.flow.FlowState.invokeNode(FlowState.java:559)

at com.wm.lang.flow.FlowState.step(FlowState.java:430)

at com.wm.lang.flow.FlowState.invoke(FlowState.java:400)

at com.wm.app.b2b.server.FlowSvcImpl.baseInvoke(FlowSvcImpl.java:1786)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:455)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:495)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:392)

at wm.PartnerMgr.gateway.transport.B2B.OutboundProcess(B2B.java:157)

at java.lang.reflect.Method.invoke(Native Method)

at com.wm.app.b2b.server.JavaService.baseInvoke(JavaService.java:281)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)

at com.wm.app.b2b.server.BaseService.invoke(BaseService.java:140)

at com.wm.lang.flow.FlowInvoke.invoke(FlowInvoke.java:292)

at com.wm.lang.flow.FlowState.invokeNode(FlowState.java:559)

at com.wm.lang.flow.FlowState.step(FlowState.java:430)

at com.wm.lang.flow.FlowState.invoke(FlowState.java:400)

at com.wm.app.b2b.server.FlowSvcImpl.baseInvoke(FlowSvcImpl.java:1786)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:455)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:495)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:464)

at wm.PartnerMgr.gateway.runtime.InboundProcess(runtime.java:423)

at pub.sap.transport.RFC.InboundProcess(RFC.java:190)

at java.lang.reflect.Method.invoke(Native Method)

at com.wm.app.b2b.server.JavaService.baseInvoke(JavaService.java:281)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:693)

at com.wm.app.b2b.server.ServiceManager.invoke(ServiceManager.java:455)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:495)

at com.wm.app.b2b.server.Service.doInvoke(Service.java:464)

at com.wm.pkg.sap.rfc.Listener.handleRequest(Listener.java:286)

at com.sap.mw.jco.JCO$Server.dispatchRequest(JCO.java:6022)

at com.sap.mw.idoc.jco.JCoIDoc$Server.dispatchRequest(JCoIDoc.java:10120)

at com.wm.pkg.sap.rfc.Listener.dispatchRequest(Listener.java:186)

at com.sap.mw.jco.rfc.MiddlewareRFC$Server.nativeListen(Native Method)

at com.sap.mw.jco.rfc.MiddlewareRFC$Server.listen(MiddlewareRFC.java:1070)

at com.sap.mw.jco.JCO$Server.listen(JCO.java:5797)

at com.sap.mw.jco.JCO$Server.run(JCO.java:5731)

at com.wm.pkg.sap.rfc.Listener.run(Listener.java:101)

at java.lang.Thread.run(Thread.java:479)

Thanks for your support on this eai.

Regards,

Laurent.

Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos

Looks like you are calling the service pub.web.documentToRecord in your flow step. Check this flow step. Somehow BC is not able to process that step correctly. Insert a savePipelineToFile step before this step, so that BC stores the pipeline.

Then load this pipeline and call documentToRecord, and check the input values in BC developer.

CSY

laurent_touillaud
Contributor
0 Kudos

Hi Christian,

Thanks very much for this answer.

I added the step but now how can i load the pipeline as you said to call documentToRecord? the input is only a file name...

In debug i can't get the xml body values.

For information after the Http post service we call the following :

1. Http (post to client)

2. bytesToString (pub_string_bytesToString)

3. stringToDocument (pub_web_stringToDocument)

3.1. Added step -> savePipelineToFile

4. documentToRecord (pub_web_documentToRecord)

stringToDocument is called with following values in debug :

<?xml version="1.0"?>

<!DOCTYPE cXML SYSTEM "http://xml.cXML.org/schemas/cXML/1.2.011/cXML.dtd">

<cXML version="1.2.011" payloadID="20080825171850716.18637uTQ9ExzheaK+H6b7O9oCAQWPzHA-9355222.8b3632def70da7220004d0b6@bcv50sde.vz.cit.xxx.fr" timestamp="2008-08-25T17:18:50-CEST">

<Response>

<Status code="500">No cXML document received from sender.</Status>

</Response>

</cXML>

and the returning string is :

"com.wm.lang.xml.Node:-1:7888849"

This string is then used for documentToRecord.

Thanks,

Points given.

Former Member
0 Kudos

Hello,

you create a new flow service, and add the step pub.flow:restorePipelineFromFile.

you use the same filename as you have used for the save Pipeline step.

(The BC stores and loads those pipelines on the server in the directory <bc>/server/pipeline)

As second flow step, you create your documentToRecord (as in the original flow).

This new flow service should now crash also. Now you debug that flow and check the input value of recordToDocument.

Same technique is applicable to track the error in more detail, maybe using savePipeline some steps earlier in the original flow

CSY

laurent_touillaud
Contributor
0 Kudos

Hi,

Ok, i got the file and placed the pipeline service after bytesToString service.

One last question :

When we call the service bytesToString the returned value mapped is empty : <value name="returnedHttp" />

Does this mean the problem is on the client side?

Best regards,

Laurent.

Former Member
0 Kudos

ok, I think we do not need the save/loadPipeline things, because you can debug the flow without that. I first thought you act as HTTP server, but you issue the client call in the flow itself.

Looking at the logs more carefully, it shows for example:

Copy failed: (Simple) No source data available: to=/returnedStatusCode(0), from=/returnHttp(0)/cXML(0)/Response(0)/Status(0)/@code(0)

But you say have that input:

<?xml version="1.0"?>

<!DOCTYPE cXML SYSTEM "http://xml.cXML.org/schemas/cXML/1.2.011/cXML.dtd">

<cXML version="1.2.011" payloadID="20080825171850716.18637uTQ9ExzheaK+H6b7O9oCAQWPzHA-9355222.8b3632def70da7220004d0b6" timestamp="2008-08-25T17:18:50-CEST">

<Response>

<Status code="500">No cXML document received from sender.</Status>

</Response>

</cXML>

So we see that your mappings assumptions do not match the result structure.

The other problem is that you get a status 500 and do not receive a cXML document, but that might be ok, depending on what parameters you pass to the other HTTP server. At least, you get a meaningful error message back from the server, meaning communication is ok.

I suggest you first correct those "copy failed" issues and then check by single-stepping where exactly the flow fails and check that input again.

By the way, when I feed the above cXML into recordToDocument, it works fine. Did you specify other input parameters besides "node" (e.g. recordName) ? And again, are you on Core Fix 8 ?

CSY

laurent_touillaud
Contributor
0 Kudos

Hi,

Actually i had this xml input with wrong debug data.

I now can use the correct file to load it into debug at start of the flow. The error is still the same as my first post but i can now follow the flow in debug the correct way. I notice now that return of http request has status 200 ok but the returned bytes in body->bytes contains only this string : "[B@2161d4"

The following service "bytesToString" maps this string to Httpreturn variable but the result is empty : "<value name="returnedHttp" /> "

This variable is then used to fill in the node that is used for service "documentToRecord" but as it is empty there is this error "Array -1". So i think the error might be at http return of bytes... (do you think so too?)

By the way BC is in Version 4.7 (Standard Encryption)

Best regards,

Laurent.

Former Member
0 Kudos

the "[B@2161d4" is just the Java representation of the byte array, that is ok. Yes, seems like the body is empty. Are you sending a multipart document ? Or receiving a multipart ?

If you like, you can insert a savePipelineToFile after your http request, then execute and export your flow and send it to me together with the pipeline file. (see contact details in my SDN account).

Then I can replay it locally and see what is going on.

But probably the HTTP body is just empty, yes. What result do you get when you execute that request in Internet Explorer (make a GET to that URL) ?

CSY

laurent_touillaud
Contributor
0 Kudos

Hi Christian,

Yes, i confirm the problem was on the return body of the client.

They failed to give http answer as some incoming data were missing.

Thanks and regards,

Laurent.

Points given.