I would almost say that if any part of a bulk operation fails, the
entire bulk operation fails (maybe rolling back the parts that did
not work) and you get a single error indicating as such, I mean,
what if you did a theoretical bulk operation that required the order
presented:
(keep in mind this is a made up scenario)
<iq from='[EMAIL PROTECTED]/balcony' type='set' id='roster_4'>
<query xmlns='jabber:iq:roster'>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
<item jid='[EMAIL PROTECTED]' subscription='rename'
to='[EMAIL PROTECTED]'/>
</query>
</iq>
At that point, you would be depending on those first two to happen
for the third to work correctly. If the first fails (or any of them)
fail, the entire bulk operation should probably fail and, ideally, be
rolled back by the target. (I'm not saying that that's easy... I'm
just saying that would be ideal)
(note: this is almost a proposal as to how I think it ought to
work ;D )
Daniel
On Nov 23, 2005, at 7:58 AM, Vinod Panicker wrote:
On 11/23/05, Alexey Nezhdanov <[EMAIL PROTECTED]> wrote:
В сообщении от Среда 23 Ноябрь 2005 14:59
Vinod Panicker написал(a):
On 11/23/05, Ralph Meijer <[EMAIL PROTECTED]> wrote:
PS: Any thoughts on the multiple iq items error handling anyone?
What do you mean? An iq may only have 1 child element.
Considering this stanza -
Sorry! The stanza should have been like this -
<iq from='[EMAIL PROTECTED]/balcony' type='set' id='roster_4'>
<query xmlns='jabber:iq:roster'>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
</query>
</iq>
What if there are errors for any of the items?
Why not do it like this?
<iq from='[EMAIL PROTECTED]/balcony' type='set' id='roster_4'>
<query xmlns='jabber:iq:roster'>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
</query>
</iq>
<iq from='[EMAIL PROTECTED]/balcony' type='set' id='roster_5'>
<query xmlns='jabber:iq:roster'>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
</query>
</iq>
<iq from='[EMAIL PROTECTED]/balcony' type='set' id='roster_6'>
<query xmlns='jabber:iq:roster'>
<item jid='[EMAIL PROTECTED]' subscription='remove'/>
</query>
</iq>
Anyways user will very rarely delete several contacts at once...
What is the
benefit from doing it in your way?
I figured since its not expressly forbidden, then why not?
Maybe bulk automated operations? Who knows?
Regards,
Vinod.