on 04-12-2006 11:35 AM
Hi,
I am working on a scenario where I am configuring a file adapter to carry an XI payload along with a .jpg attachment. This is received by a mail adapter.
I have used a standard ejb on my mail receiver adapter side, where I have given the following specifications for my attachment
Transform.ContentDescription Filename.jpg
Transform.ContentDisposition attachment
Transform.ContentType image/jpeg
I have given a random module key in the configuration.(say 1)
The processing sequence is
1) attachment module
2) mail module
I am receiving the attachment as <b>filename.jpg.jpg</b> and it shows 250 Bytes in the mail whereas the actual size of the .jpg being sent is about 80 Kb.
Also, if i download this file, it says the size is 0 Kb.
Is the file getting corrupted somewhere?
Please let me know what the problem could be.
Thanks,
Prashanth
Hi,
My scenario is file to mail
Iam placing a .txt file in a folder.this file has to get picked by File adapter and then should be sent to email inbox as same .txt attachement.
i have configured the adapter in module tab as
TEST Transform.ContentDescription FileInput
TEST Transform.ContentDisposition attachment
TEST Transform.ContentType text/txt;name="FileInput.txt"
Iam getting an error as "com.sap.aii.utilxi.misc.api.BaseRuntimeException: Fatal Error: com.sap.engine.lib.xml.parser.ParserException: XMLParser: No data allowed here: (hex) 69, 6e, 70(:main:, row:1, col:3) at com.sap.aii.mappingtool.tf3.Transformer.checkParserException" in moni.Kindly help me out
Regards
Madhu
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello MadhuLatha,
Are you not doing any mapping with the file ,If not then what is the need of using messagetransform bean ,When you can send the file as attachment by selecting the messageprotocol as XIPAYLOAD and check keepattachements in the mail adapter.
Let me know if i am not clear or if your req is diff
Regards
Rajesh
hi Michal,
Done deal..I used payload swap bean instead of message transform and got the jpeg payload as a .xml file.
When i save it as .jpg, I get the jpeg file.
What parameter do i use in payload swap bean to get the jpg directly as the attachment, and not as an XML?
thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Michal,
One more thing... You were right.. I downloaded the attachment again now.., and saved it as .xml. It shows my target mapping xml
What did I do wrong?
cheers,
prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
>>>>You were right.. I downloaded the attachment again now.., and saved it as .xml. It shows my target mapping xml
I told you this is your message payload
jpg is not in the payload
you need to do it as I've shown you
I'll try to check changing the name of the jpg today
and I'll let you know if this is possible too
Regards,
michal
Hi Michal,
Also, when I am specifying the params for additional files, what do I give in the file.encoding?
thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Michal,
My content type is image/jpeg.
Is that right??
Also, Do I specify the file to be picked as file.jpg or just file(without the extn)??
thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Michal,
First of all, a very happy Easter to you!
I am getting the attachment as file.jpg(200Bytes) with the mail, but when I download it, it shows 0 bytes.
Could you tell me where I could have made a mistake?
thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Michael,
It doesnt open as an XML also.
Great that it works on urs, but are u able to retrieve the file? Does the jpg come in as an attachment?
cheers,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
>>>Does the jpg come in as an attachment?
yes it does when I change the content type
to image/jpeg in a simple adapter module
I can see a jpg in the attachment and when I open
it it's the same one as the one that was
pulled by the file adapter
I only had problems with the jpg's name
but I believe it can also be solved easily
and I'll try to do it after Easter
Regards,
michal
hi,
>>>>I am working on a scenario where I am configuring a file adapter to carry an XI payload along with a .jpg attachment
so you have xml + jpg right?
>>>I am receiving the attachment as filename.jpg.jpg and it shows 250 Bytes in the mail whereas the actual size of the .jpg being sent is about 80 Kb.
how big is your xml file?
try downloading the filename.jpg.jpg and savinf it
as xml and check if you can open it
maybe it's not the jpg but xml saved with jpg extension
check it and let me know
BTW
your scenario works at my dev XI
Regards,
michal
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Stefan,
Thanks a ton for your answer. I tried out as you told me to, but I am still not able to get the attachment in its initial size.
I presume that it is getting corrupted on the way somewhere, but I cant figure out where.
Could you help me out on that?
Thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Prashanth,
1. The filename of the attachment is assembled from descriprion + content type. So set the description to filename without suffix.
2. The file has to be declared as binary in the file adapter settings. Otherwise the file adapter tries to convert the file to UTF-8, which does not make any sense with non-text files.
Regards
Stefan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
Could someone help me out on this?
thanks,
Prashanth
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
87 | |
10 | |
10 | |
10 | |
7 | |
6 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.