cancel
Showing results for 
Search instead for 
Did you mean: 

Adapter Module

Former Member
0 Kudos

Hi All,

These are fundamental question on Adapter Module Development, which I could nt find in any documents.

1) In a Sender communication channel, when the payload is converted to XML? I mean before the payload reaches the

module or after the last module is called? Also how about the receciver communication channel, ie, at what step the XML is converted into respective formats to be delivered to the target system?

2)In all the codes while writing modules, the following line of code is used to get the payload (People say its XML Payload, where I am confused).

XMLPayload xmlpayload = msg.getDocument()

;

SAP says that XMLPayload is a payload that represents a XML document.But to my understanding, the original payload is passed on to the module. If it is a flat file, how the payload can be a XML ? Insted, it should have been returning a object of type payload.(It may be my lack of understanding, but pls explain).

I am asking this, as I can see in some examples, if it is a flat file, it is read each byte by byte to change the payload, and if it is a XML file, it is parsed by DOM/SAX parser and then other changes are done. This brings me to the confusion.

Thanks,

SS

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Hi

1) If the adapter provides xml conversion "out of the box", it is done before entering the module chain for sender channels, and right before delivering the message for receiver channels. In every case, you'll always manage an xml inside your custom module (unless the adapter doesn't convert the payload, e.g. file adapter with no content conversion).

2) you could also use msg.getMainPayload(), which returns a Payload object to handle text payloads, but I think it wouldn't hurt even if you had used XMLPayload for that.

cheers

Daniele

Former Member
0 Kudos

Hi Daniele,

Thanks for the answer.

Can you please explain the phrase 'out of box' please?

Also can I conclude that, the XML conversion first takes place using the Message Protocols ( with additional info in FCC incase of File Sender CC), then the message is transmitted to the module chain?

Is the text payload only restricted (valid for) to File Adapter without FCC ?

Regards,

SS

Former Member
0 Kudos

> Can you please explain the phrase 'out of box' please?

I meant adapters that perform xml conversion without using modules, like the sender jdbc adapter or file with Content Conversion.

> Also can I conclude that, the XML conversion first takes place using the Message Protocols ( with additional info in FCC incase of File Sender CC), then the message is transmitted to the module chain?

Yep

Is the text payload only restricted (valid for) to File Adapter without FCC ?

I think you can have that also for jms an custom adapters as well.

best,

Daniele

Answers (0)