Recevie the xml that is posted to TN in the form of "BoundedInputStream".

1.One of our TN partners is using GIS to post xml documents and we are receiving them in TN in the following form
and not able to see the xml in the “Content” tab:

One entry in the content tab:
name: bytes
length: 346
type: application/x-wmidatabin

Content stream: com.wm.app.b2b.server.BoundedInputStream

TN_parms:
TN_parms/$contentType: application/octet-stream
TN_parms/$contentEncoding: null


  1. If I use the same xml and post using the “Document Submission”, I am getting the xml in the content.
    Following are the details:
    name: xmldata
    length: x,xxxx
    type: text/xml, charecter set=utf8

So my question is how to convert the “BoundedInputStream” to xmldata and retrive the xml?
Are there any other possible solutions?

One option would be either tell your partner to send in webMethods expected format with content-type=text/xml,that hits tn:receive gateway service.

Another option would be create a custom gateway service with service input as contentStream,further down in the flow convert stream to string and validate the xml before routing to TN via routeXML service.

HTH,
RMG

Thank you for your response. We have asked the user to set content-type to “text/xml”, but they couldn’t figure that out.

They are using GIS to send the xmls. Do you know what that is?

Also can you please let me know how to convert content stream to string? If possible can you provide me the flow service name which does this conversion.

GIS-Gentran Integration Suite --another middleware tool by SterlingCommerce,i believe it should have capability of sending contenttype as text/xml while doing http post.

HTH,
RMG

RMG,

I am also having the same problem.I am trying to follow your solution . I checked the WmPublic services but i didnt find any service which takes contentStream as Input.could you please elaborate on how to create a gateway service with contentStream as input?

Thanks In Advance

Raj,

You should find these services pub.io:streamTobytes,pub.string:bytesToString in WmPublic package,

Make sure your service input should be contentStream(object) map this input to streamTobytes and follow the rest.

HTH,
RMG

We created gateway service as indicated above. But when we gave the URL to this gateway service to our
partner, they are receiving “Invalid credentials” when they access this gateway service.

We added the uid that we have given to our partners in “Adminstrators” group.
We checked with our Network group to make sure that there is not firewall issue.

But still my partners are getting “Invalid credentials”.

So we
1. Can’t use gateway servive because of “Invalid credentials” problem.
2. Even though we registered content_type ->application/octet-stream in our IS,
we still are not able to receive the xmls posted by partner and seeing
“com.wm.app.b2b.server.BoundedInputStream” in content stream.

Are there any more options of receiving the xmls from the partner? We are stuck with this problem for a long
time. Your help is greately appreciated.

What is your gateway service input?Please tell us your flow.

Well registering the content handler should work,where did you set this is it IS/lib/mime.types file?Restart the IS.

Did you tried debugging with getTransportInfo service and check the pipeline whats going on?

HTH,
RMG

We have the below steps in our gateway service
1. streamToBytes with object as input
2. bytesToString
3. xmlStringtoXMLNode
4. wm.tn.receive

We installed WmEdiInt and used addContentType to register the content type “application/octect-stream”
We see the following entry in IS/lib/mime.types file:
application/octet-stream * bin class dms exe lha lzh

  1. Does this mean it is registered? We didn’t restart the server though. We will try.

  2. Where is “getTransportInfo”?

  3. How can we post xml to the url that ends with -->invoke/wm.tn/receive other than document submission.
    This is because we want to see what our partner is experiencing?

    I have developed a small html page with textarea that submits the page to node and
    put the xml to post to invoke/wm.tn/receive url

My question here is:
how to test posting xml to the URL?

Sudeshna,

yes if you see the content type in lib/mime.types file,then it is registered in IS content handler.

pub.flow:getTransportInfo (browse this service in WmPublic/pub/flow folder)you can use find service option in developer tool

For testing http xml posts you can stimulate with pub.client:http service and map the inputs specify the url
[url]http://localhost:5555/invoke/wm.tn/receive[/url] with method=post
map xml string or bytes to data/string or bytes
set input headers/Content-type=text/xml

Run the http service,this will post the xml to TN.

Please go thru the IS Builtin services userguide about the mentioned services.

HTH,
RMG