JMS to IDoc - Sequence / Numbering
I'm a little confused about this behavior, maybe you could give me some ideas on why this is happening.
I have a JMS (MQ) --> PI --> ERP scenario where the messages on MQ are of course in sequence.
I configured my JMS sender adapter with QoS EOIO and gave some arbitrary Queue ID (Z_GAL1) and the Cluster ID (Its not actually a cluster, but only one server node)
I also configured the interface determination to use EOIO
I intentionally didn't activate the IDoc receivers "use queue processing" because we have multiple IDocs that need to be processed in sequence but only if they share the same order number which is in the payload of the IDoc. Having fully queued proccessing would mean that any error in a previos IDoc would lead to a stop of the queue even if IDocs with other order number could be processed successfully.
So the strange thing is this: MQ provides the messages in strict FIFO sequence. PI receives those messages in the correct order. This is visible in communication channel monitoring. However, the generated IDoc Numbers are not in sequence.
- Is this a normal behavior of the IDoc adapter on PI (7.0 Dual Stack)
- I know about IDoc / ALE serialization. I could fill in SERIAL field. However, since we have another legacy system that posts those IDocs to ERP which in fact creates IDocs in strict FIFO sequence and inbound processing for those is already working and tested I would like to have PI behave the same way as much as possible as the legacy system. Is there a way to accomplish this?
Jens Schwendemann replied
after some testings on new SAP PI 7.4 AEX (original tests carried out on SAP PI 7.0 Dual Stack) it seems that by specifying the following parameters in the sender JMS adapter does the trick
QoS = EOIO
Queue ID = Some arbitrary name like "MyIdoc"
Processing J2EE Cluster Server = Your Cluster ID. Probably also would work if left blank
So as of now I'm not quite sure if I didn't carry out all the steps on PI 7.0 correctly or if this behavior was changed in PI 7.4. Anyway, the Messages get picked up from JMS Queue in the correct order an IDoc numbers are getting created in a sequential way.
I then filled in the SERIAL field with a built in function "currentDate" / Target Date Format = "yyyyMMddHHmmssSSS" in normal graphical message mapping.
I did not activate Queue Processing on the receiver IDoc adapter nor the assosiated port (WE21) in corresponding ERP system.
I configured the partner profile in ERP for background processing so the IDocs get collected in ERP and then processed periodically with a job that puts the IDocs in the correct order according to the SERIAL field.
Hope this helps someone out there