Subject: [Simple] Extending the xmlschema in draft-ietf-simple-xcap-diff-05

From: "Anders Lindgren C (TN/EAB)" <[email-masked]>
Date: Fri, 1 Jun 2007 17:25:30 +0200

Hello Jonathan,
The http://tools.ietf.org/html/draft-ietf-simple-xcap-diff-05 describes
a format how to sending information about the changes of an xcap
document.
In some situation it is useful be able to include more information in
the change log than just what has been changed. Information that can be
useful to have is when the changed occured, who did the change and the
etag before and after the change. I have tried to find a way of adding
such new elements but failed.

My proposal is to change the xml schema in such away that it is
posssible to add new attributes the elements <add>, <remove> and
<replace> making it possible to define a document like
<?xml version="1.0" encoding="UTF-8"?>
   <xcap-diff xmlns="urn:ietf:params:xml:ns:xcap-diff"
       xmlns:ns="newnamespace">
    xcap-root="http://xcap.example.com/root">
    xmlns:ns="newnamespace">
    <document new-etag="7ahggs"
     doc-selector="resource-lists/users/joe/coworkers"
     previous-etag="8a77f8d"/>
     <change-log>
        <add sel="*/elem[@a='bar']" type="@b" ns:timestamp="2007-05-30"
ns:changed-by="bob" previuos-etag="8a77f8d" new-etag="9ddgsds">new
attr</add>
        <add sel="........." Type="-----" ns:timestamp="2007-06-01"
ns:changed-by="joe" previuos-etag="9ddgsds"
new-etag="7ahggs">------</add>
      </change-log>
   </xcap-diff>
    
If I understand it correctly it is the definitions below that needs to
be changed to allow new attributes to be added.

    <xs:element name="add" type="add"/>
    <xs:element name="remove" type="remove"/>
    <xs:element name="replace" type="replace"/>
    
They need to be of the form

<xsd:element name="add">
  <xsd:complexType>
    <xsd:complexContent>
      <xsd:extension base="tns:add">
        <xsd:anyAttribute processContents="lax"/>
      </xsd:extension>
   </xsd:complexContent>
 </xsd:complexType>
</xsd:element>

instead.

It might also be useful to be able to reuse the attributes
"previuos-etag" and "new-etag" in the <document> element also as
attributes to the <change-log> child elements above.
It would be nice to get your comments on this issue.
Regards
Anders

_______________________________________________
Simple mailing list
[email-masked]
https://www1.ietf.org/mailman/listinfo/simple

---

From: Jonathan Rosenberg <[email-masked]>
Date: Thu, 07 Jun 2007 14:55:38 -0400

I think its reasonable to want this kind of extensibility.

I'd probably argue that this would be better defined in the patch-ops 
draft than here, but I don't feel very strongly on that.

I'm not sure I understand the meaning of the etags within the change 
elements. Can you explain a use case for that?

-Jonathan R.

Anders Lindgren C (TN/EAB) wrote:

> Hello Jonathan,
> The _http://tools.ietf.org/html/draft-ietf-simple-xcap-diff-05_ 
> describes a format how to sending information about the changes of an 
> xcap document.
> 
>       * **xmlns:ns="newnamespace*">
>         <add sel="*/elem[@a='bar']" type="@b"* ns:timestamp="2007-05-30" 
> ns:changed-by="bob" previuos-etag="8a77f8d" new-etag="9ddgsds"*>new 
> attr</add>
> 
>         <add sel="........." Type="-----"* ns:timestamp="2007-06-01" 
> ns:changed-by="joe" previuos-etag="9ddgsds" new-etag="7ahggs"*>------</add>
> 
>       </change-log>
>    </xcap-diff>
>    

-- 
Jonathan D. Rosenberg, Ph.D.                   600 Lanidex Plaza
Cisco Fellow                                   Parsippany, NJ 07054-2711
Cisco Systems
[email-masked]                              FAX:   (973) 952-5050
http://www.jdrosen.net                         PHONE: (973) 952-5000
http://www.cisco.com

---

From: "Anders Lindgren C (TN/EAB)" <[email-masked]>
Date: Fri, 8 Jun 2007 17:14:56 +0200

My view is that if you have XCAP, one change log element will in most
situations create a new etag value. This means that if you have a
sequence of changelog elements it might be good to know how every change
log element changed the etag value.

One possible use case that I see it that the client do a Subscribe for
document changes and receives a first Notify with the XCAP URI to the
document.
The Notifier has some kind of time based rate limitation and  number of
changes are done in the document.
The client is fetching the XCAP document and get a newer version than
the one if the first Notify(Etag is different then the one in the
Notify).
The Notifier finds out that it is time to send a Notify and does that by
sending a Notify with a sequence of change log element. If the client
receives per change log element information about etags, the client is
able to patch the version it has as it can skip all change log elements
up to the one with the previous etag equals its documents etag.
Br
Anders

-----Original Message-----
From: Jonathan Rosenberg [mailto:[email-masked]] 
Sent: den 7 juni 2007 20:56
To: Anders Lindgren C (TN/EAB)
Cc: [email-masked]
Subject: Re: Extending the xmlschema in draft-ietf-simple-xcap-diff-05

-Jonathan R.

Anders Lindgren C (TN/EAB) wrote:

> the change log than just what has been changed. Information that can 
> be useful to have is when the changed occured, who did the change and 
> the etag before and after the change. I have tried to find a way of 
> adding such new elements but failed.
> 
> new-etag="7ahggs"*>------</add>
> 
>       </change-log>
>    </xcap-diff>
>