cancel
Showing results for 
Search instead for 
Did you mean: 

File to JMS without using IR

Former Member
0 Kudos

Hi,

File (PDF) -->XI -->JMS (with using IR)

As per the well known blog by William Li /people/william.li/blog/2006/09/08/how-to-send-any-data-even-binary-through-xi-without-using-the-integration-repository

It is possible to send any data from any adapter to any adapter.

I am not sure if someone has tested this with Receiver JMS adapter because in my case when I am sending the PDF file to JMS then it is not reaching as PDF at MQ end. The MQ people are saying that the message is coming as "JMS Text".

In XI RWB I can see the PDF was sent successfully so no issues in XI.

Has anyone faced the same issue or am I missing something?

Thanks!

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi,

I wonder if this relates to the binary content of the PDF file. Have you tried using a BASE64 conversion.

You can use either an user-module or java mapping to encode the binary to ASCII format. Once it is received on MQ, you can do a a decode.

The BASE64 encoding/decoding routines are quite simple and there are a lot of examples on the internet.

Regards,

Bill

Former Member
0 Kudos

Thanks a lot William for your quick reply!

Actually this not related to binary content of PDF. I am picking the PDF file without using Repository and trying to send it to receiver JMS adapter as it is without any modification. The MQ team says that they are getting the payload as JMS Text.

Answers (4)

Answers (4)

former_member200962
Active Contributor
0 Kudos
The MQ people are saying that the message is coming as "JMS Text".

the message that is send by JMS adapter of PI is treated as TEXT once it reaches the MQ...even if you try setting the content-type to XML (or any other value) wont help.....this property is very specific to MQ.

We had the same error while sending message using JMS adapter of PI....then we shifted to HTTP adapter which solved the issue....the messages are no longer visible as TEXT in the MQ.

I am doubtful if anything in PI-JMS can be helpful to modify this parameter.

Former Member
0 Kudos
the message that is send by JMS adapter of PI is treated as TEXT once it reaches the MQ...even if you try setting the content-type to XML (or any other value) wont help.....this property is very specific to MQ.
We had the same error while sending message using JMS adapter of PI....then we shifted to HTTP adapter which solved the issue....the messages are no longer visible as TEXT in the MQ.
I am doubtful if anything in PI-JMS can be helpful to modify this parameter.

Hi Abhishek,

I did some research and found the solution. I have made the blog for the same..

/people/sarvesh.singh3/blog/2011/05/13/how-to-send-pdf-zip-or-jpeg-via-receiver-jms-adapter-to-mq

Thanks to everyone!

former_member181985
Active Contributor
0 Kudos

Also, if it is webshpere MQ JMS ensure that u select "JMS compliant" option under the drop down.

Former Member
0 Kudos

Yes, "JMS compliant" is the value I am using in my adapter.

Shabarish_Nair
Active Contributor
0 Kudos

can you use messagetransformbean and set the content type to application/pdf and try?

Former Member
0 Kudos

Thanks!

I will try this and update the thread if it works.

Update:-

This didn't work. MQ people says "The PDF is included in the payload but it is wrapped in MIME or Base64 since the message is text rather than binary and the PDF has been garbled." But from audit log I can see "XI message in binary format forwarded to the XI JMS service successfully".

Has anyone tested such kind of scenario with receiver JMS adapter.

Edited by: Sarvesh Singh on May 10, 2011 7:22 PM

former_member181985
Active Contributor
0 Kudos
Former Member
0 Kudos

The module sequence is the default one as mentioend below, so I don't think this should create any problems.

1. localejbs/SAP XI JMS Adapter/ConvertMessageToBinary

2. localejbs/SAP XI JMS Adapter/SendBinarytoXIJMSService

Any other ideas?

Note: I am on XI 3.0 SP22.