cancel
Showing results for 
Search instead for 
Did you mean: 

receiver mail adapter - Payload as a Text attachment

former_member205101
Participant
0 Kudos

Hi,

In my proxy to mail adapter scenario, when i want to send payload to email as a Text email, where i need to content conversion in XI (XML to Txt file)

when i send payload, currently i am receiving as a XML file.

I try to follow like Rushikesh Deshmukh XI thread: Text Attachment in Mail Adapter in XI forum(topic)

.......................................

"

I have having following config

Processing Sequence

localejbs/CreateAttachment Local Enterprise Bean XML2Plain

localejbs/sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean Local Enterprise Bean mail

Module Configuration

XML2Plain Transform.Class com.sap.aii.messaging.adapter.Conversion

XML2Plain Transform.ContentType text/plain;charset=utf-8

XML2Plain xml.Header1000.fieldFixedLengths 100,10,10,30,30,80,80,20,10,10,20,20,30,10,18,240,10,30,18,10

XML2Plain xml.Header2000.fieldFixedLengths 100,30,40,240

XML2Plain xml.addHeaderLine 0

XML2Plain xml.conversionType StructXML2Plain

XML2Plain xml.recordsetStructure Header1000,Header2000

Please suggest some solution."

.....................

Could you tell me exactly where i need to do all these setting and

do i need import localejbs/CreateAttachment Local Enterprise Bean XML2Plain...I mean shall i add same in my processing sequence

give in detail ? (in Receiver mail adapter Communication channel, advanced mode additional parameters)

I tried to follow this also

http://help.sap.com/saphelp_nw04/helpdata/EN/4e/c153426da9bd30e10000000a155106/frameset.htm

but i could not find much info on this help.sap.com reg. req.

Thanks

Prabaharan

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi

You can use Java Mapping in Mapping to create the XML file to Text and then you can create Mail package as final output.

use this blog as base and addition you should do is parse content from XML to TEXT.

This will allow you to use Mail package with attachments as receiver. Problem is resolved !!!

Thanks

Gaurav

former_member205101
Participant
0 Kudos

Hi,

I want to avoid Java Mapping.

Thanks for ur reply.

I want to follow these things which posted in XI forum for TXT file in Receiver email.

I have few questions:

if i create like this Receiver CC (module Tab)

number: 1

Module Name: localejbs/CreateAttachment

Module Type: Local Enterprise Bean

Module Key: mail

is it enough? do i need any other setting like this

this module Name I can create anything?

Processing Sequence

localejbs/CreateAttachment Local Enterprise Bean XML2Plain

localejbs/sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean Local Enterprise Bean mail

Module Configuration

XML2Plain Transform.Class com.sap.aii.messaging.adapter.Conversion

In this:

Module Key: XML2Plain

Parameter Name: Transform.Class

Parameter Value: com.sap.aii.messaging.adapter.Conversion

is it right?

XML2Plain Transform.ContentType text/plain;charset=utf-8

XML2Plain xml.Header1000.fieldFixedLengths 100,10,10,30,30,80,80,20,10,10,20,20,30,10,18,240,10,30,18,10

XML2Plain xml.Header2000.fieldFixedLengths 100,30,40,240

XML2Plain xml.addHeaderLine 0

XML2Plain xml.conversionType StructXML2Plain

XML2Plain xml.recordsetStructure Header1000,Header2000

can i anyone explain how to these settings?

Thanks

Prabaharan

Former Member
0 Kudos

Hi

f i create like this Receiver CC (module Tab)

number: 1

Module Name: localejbs/CreateAttachment

Module Type: Local Enterprise Bean

Module Key: mail

is it enough? do i need any other setting like this

Did you deployed CreateAttachment on PI server. As this is not a standard SAP module this is a custom module?

mail as module key is already used by XIMAILAdapterBean use some other key for CreateAttachment

Settings are fine for the Module

Processing Sequence

localejbs/CreateAttachment Local Enterprise Bean XML2Plain

localejbs/sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean Local Enterprise Bean mail

Module Configuration

XML2Plain Transform.Class com.sap.aii.messaging.adapter.Conversion

In this:

Module Key: XML2Plain

Parameter Name: Transform.Class

Parameter Value: com.sap.aii.messaging.adapter.Conversion

is it right?

Processing sequence is fine

XML2Plain Transform.ContentType text/plain;charset=utf-8

XML2Plain xml.Header1000.fieldFixedLengths 100,10,10,30,30,80,80,20,10,10,20,20,30,10,18,240,10,30,18,10

XML2Plain xml.Header2000.fieldFixedLengths 100,30,40,240

XML2Plain xml.addHeaderLine 0

XML2Plain xml.conversionType StructXML2Plain

XML2Plain xml.recordsetStructure Header1000,Header2000

can i anyone explain how to these settings?

Is this key valid to provide inputs to the module check with the code for this module

This looks like valid for MessageTransformBean ro StrictXMLtoPlainBean

Thanks

Gaurav

Edited by: Gaurav Bhargava on Oct 15, 2008 5:34 AM

former_member205101
Participant
0 Kudos

HI Gaurav,

Thanks for ur immediate response.

I use PI 7.0 (ie NW04S_14_REL SP 14)

Did you deployed CreateAttachment on PI server. As this is not a standard SAP module this is a custom module?

I did n't deploy that CreateAttachment on PI server.

I want to use existing one in PI server.

If i want to use existing Module Name for req.

How can i check what are the Modules which are displayed in PI server.

Now i try to use localejbs/AF_Modules/MessageTransformBean

or shall i use like this do u think it will be avaiable like this in any PI system

sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean/localejbs/AF_Modules/MessageTransformBean

how can i really use existing Module for this req.?

Thanks

Prabaharan

Edited by: Prabaharan on Oct 15, 2008 2:14 AM

Former Member
0 Kudos

Hi

If you want to use the existing List is

● PayloadSwapBean

You can swap the main payload of the XI message with another payload of the message that is an attachment.

● StrictXml2PlainBean

You can convert an XML document in the main payload of the XI message to text format.

The structure of the document is checked based on the entries you make in the module.

● XMLAnonymizerBean

You can anonymize XML elements and attributes.

● PayloadZipBean

You can compress one or more payloads or extract payloads from a compressed file.

● TextCodepageConversionBean

You can swap the code page of the main payload of the XI message and convert the content using the new code page.

● DynamicConfigurationBean

You can edit the message header for adapter-specific message attributes.

● MessageTransformBean, Migrating Dispatcher Classes

Now your requirement is to convert a XML file into Text and send as attachment then

You need to use

1. StrictXml2PlainBean - this will change your XML to TEXT

2. MessageTransformBean - this will change payload as attachment

Thanks

Gaurav

former_member205101
Participant
0 Kudos

Hi,

if i want to use ,

.1. StrictXml2PlainBean - this will change your XML to TEXT

( i think u made typo error..correct one will be : StructXML2PlainBean)

2. MessageTransformBean - this will change payload as attachment

if i want to use both of these (StructXML2PlainBean & MessageTransformBean)

what will be module name and module type in my processing sequence ( ie in the receiver mail adpater CC)

I try to follow ur comments and this Link (i tried earlier)

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/50061bd9-e56e-2910-3495-c5faa652...

if possible send me some link which explains concept very well so that i try follow that.

former_member205101
Participant
0 Kudos

HI Gaurav,

Thanks for ur help.

I found the link:

http://help.sap.com/saphelp_nw04/Helpdata/EN/2e/bf37423cf7ab04e10000000a1550b0/frameset.htm

I found ur bean which u mentioned " StrictXml2PlainBean"

u mean to say i have to use this one for Mail receiver adapter ( main payload of the XI message to text format)

how to enter these module in my processing sequence?

can i use AF_Modules/StrictXml2PlainBean module name

number 1

local enterprise bean

moudle key as XML2Plain

Thanks

Prabaharan

Thanks

Prabaharan

former_member205101
Participant
0 Kudos

HI,

I am using in processing sequence like this (receiver mail CC)

Number: 1

Module Name: AF_Modules/StrictXml2PlainBean

Module Type: Local Enterprise Bean

Module Key: XML2Plain

I do not know whether i have AF_Modules/StrictXml2PlainBean on my PI server.

How to check whether i have this or not?

if not how to deploy this?

.................

Number: 2

Module Name: sap.com/com.sap.aii.adapter.mail.app/XIMailAdapterBean

Module Type: Local Enterprise Bean

Module Key: mail

..............

In the module Configration

what i need to give, if i have single recordset only?

already i tried many ways..i could not succeed..

Thanks

Prabaharan

Answers (2)

Answers (2)

former_member205101
Participant
0 Kudos

I am opened new thread

Former Member
0 Kudos

try this blog..

/people/prasad.ulagappan2/blog/2005/06/07/mail-adapter-scenarios-150-sap-exchange-infrastructure

check the option 2..Message Protocol

2. Message Protocol = u201CXIPAYLOADu201D with u201CMail Packageu201D

Edited by: Anand on Oct 14, 2008 7:18 PM

former_member205101
Participant
0 Kudos

HI anand,

In ur link web blog again refers Michal Web blog,

to achieve XML to TXT conversion in receiver mail.

I could not see complete details for XML to TXT conversion settings for Receiver CC in that blog.

I need to know how to achieve TXT file in Email as a Attachment.

could any one send me complete details about that.

I could not find any one single web blog explains complete details...(may be i am poor in searching blogs in SDN)

is it simple to achieve like TXT file in the Receiver Email.?

Thanks

Prabaharan

Former Member
0 Kudos

ignore his blog..but did you follow the option in the blog...Blog says only the change in settings will help, but i haven't tried.

2) Message Protocol = u201CXIPAYLOADu201D with u201CMail Packageu201D