OASIS Mailing List ArchivesView the OASIS mailing list archive below
or browse/search using MarkMail.


Help: OASIS Mailing Lists Help | MarkMail Help

ebxml-transport message

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Subject: RE: SequenceNumber and ordering


See comments below.


-----Original Message-----
From: jacques durand [mailto:jacques@savvion.com]
Sent: Thursday, January 04, 2001 4:35 PM
To: Nikola Stojanovic
Cc: ebXML Transport (E-mail)
Subject: Re: SequenceNumber and ordering

Nikola Stojanovic wrote:

> <SHIMAMURA Masayoshi>
> ...
> (1) Guarantee of Message Order
> (2) Effective Duplication Check
> The MessageID element in MessageData can not realize the two functions
> above. Especially, there is no way to guarantee Message Order except for
> using SequenceNumber. Because current MS specification has not the
> blocking restriction. The Sender can send some messages without waiting
> for acknowledgement message. Thus when a communication error and retry
> sequence occurs, sent messages will reach the Receiver in invalid order.
> To correct the invalid order in the Receiver, the SequenceNumber must be
> included in each message.
> </SHIMAMURA Masayoshi>
> In addition to MessageID element in MessageData there is a RefToMessageId
> element as well. While using MessageID only for the purpose of temporal
> ordering of messages (sequencing being just one instance of it) is not
> enough, utilizing both MessageID and RefToMessageId can allow MS Handlers
> do sequencing and much more. In that case SequenceNumber doesn't need to
> included in each message.

We had, in the Tokyo POC demo, a bad last minute experience with
It was due to divergent vendor interpretations of its "optional" use for
where one vendor required it for sequencing, while the other did not, in a
standard message exchange.
(also, should RefToMessageId of a response message sent by A,
refer to the last message *received* by A, or to the previous message *sent*
Only the latter would amount to sequence numbers. )
<DB>It should be a received message. However the spec defines RefToMessageId
as follows ...

>>>The RefToMessageId element has a cardinality of zero or one. When
present, it MUST contain the MessageId value of an earlier ebXML Message to
which this message relates. If there is no earlier related message, the
element MUST NOT be present.<<<

This is vague. It should say "... it MUST contain the MessageId value of an
earlier ebXML Message, **received by the MSH**, to which this message
relates ..."


More radically, I think RefToMessageId is great for linking Ack and Normal
messages, or
Normal and Error messages, but not Normal to Normal messages:
<DB>One the main reasons for RetToMessageId is so that the sender of a
message *knows* that an earlier message they sent was received. For this
purpose the receipt of another Normal message is equally as effective as an
acknowledgement or an error.</DB>

it should not be used for message ordering that has application semantics.
<DB>It isn't except that a MSH can use it to determine that a message has
been delivered, inform the application that this has occurred, so that the
application then resends the message.</DB>

MessageID is a MSH concept, generated by the MSH
and normally not visible at application level. 
<DB>I agree.</DB>

Requiring the application to
access it and use it
to order its messages is somehow contrived.
<DB>I'm not suggesting this.</DB>

 Message ordering that depends on
message content
(rather than on  timestamp) should rather be left to the  application level,
and rely on app-level IDs, like  DocumentId.
<DB>I agree, but message ordering that is dependent on an application being
told by a MSH that an earlier message has been delivered is what I'm

In particular,  the MSH (unlike the application) cannot enforce a partial
message order like:

>       1st Message [MessageId = a]
>       2nd Message [MessageId = b, RefToMessageId = a]
>       3rd Message [MessageId = c, RefToMessageId = a]
>       4th Message [MessageId = d, RefToMessageId = b]
>       5th Message [MessageId = e, RefToMessageId = c]

as the MSH cannot do more than mapping this "message tree"
into a sequence when returning it to the app level, leaving to the app the
figuring the reference links.
I guess most of the time, a combination of conversation ID and document
is even sufficient for an app to identify the next message of an exchange,
in RosettaNet PIPs.

I tend to think that if supporting ordering at MSH level makes  sense, it is
mostly for temporal ordering,
where  correcting the receiving order so that it reflects  the sending order
is just a property of the "connection" (a QoS attribute),
as done for packets that can take different routes in a transport layer.
(note that "connection" may have business definition, e.g. a conversation).
In which case, like for packets, sequence numbers are quite effective and
to use.
<DB>I agree with your last description of the main use of sequence

> It is not easy for me to understand a full meaning of "Effective
> Check", but I can't see a problem in using the approach explained in the
> current MS spec (0.9a) (again, without SequenceNumber).

I believe duplicate checks would require maintaining and searching a
large database of MessageIDs, on the receiver side.
Even if this one is indexed/ordered, the high rate of updates (add / remove)
would shift the
overhead from search to maintenance of the index.
The same check over seq nbrs only requires searching over a limited number
intervals of integers. Less overhead, both space and time.


Jacques Durand

> <SHIMAMURA Masayoshi>
> To realize (1)Guarantee of Message Order and (2)Effective Duplication
> Check, the SequenceNumber is obviously needed.
> </SHIMAMURA Masayoshi>
> See comments above.
> Regards,
> Nikola

[Date Prev] | [Thread Prev] | [Thread Next] | [Date Next] -- [Date Index] | [Thread Index] | [Elist Home]

Search: Match: Sort by:
Words: | Help

Powered by eList eXpress LLC