1
0
mirror of https://github.com/moparisthebest/xeps synced 2024-11-24 02:02:16 -05:00
This commit is contained in:
stpeter 2011-06-20 10:52:25 -06:00
parent 8415db3774
commit cdc0e5a423

View File

@ -30,10 +30,20 @@
&dcridland;
&mwild;
<revision>
<version>1.3rc3</version>
<version>1.3rc4</version>
<date>in progress, last updated 2011-06-20</date>
<initials>psa/mw</initials>
<remark><p>Corrected the value of 'h' in several examples; removed an extraneous 'stanzas' attribute from one example; clarified terminology; added note about the order of events in the stream negotiation process.</p></remark>
<remark>
<ul>
<li>Specified that 'h' is REQUIRED when sending &lt;resume/&gt; or &lt;resumed/&gt;, and clarified how to set its value</li>
<li>Mentioned the possibility of duplicate stanzas</li>
<li>Clarified terminology to use 'client' and 'server' instead of 'initiating entity' and 'receiving entity'</li>
<li>Added note about the order of events in the stream negotiation process</li>
<li>Corrected the value of 'h' in several examples</li>
<li>Removed an extraneous 'stanzas' attribute from one example</li>
<li>Corrected the schema</li>
</ul>
</remark>
</revision>
<revision>
<version>1.2</version>
@ -236,7 +246,7 @@ S: <failed xmlns='urn:xmpp:sm:3'>
<p class='def'><strong>Definition:</strong> Acknowledging a previously-received ack element indicates that the stanza(s) sent since then have been "handled" by the server. By "handled" we mean that the server has accepted responsibility for a stanza or stanzas (e.g., to process the stanza(s) directly, deliver the stanza(s) to a local entity such as another connected client on the same server, or route the stanza(s) to a remote entity at a different server); until a stanza has been affirmed as handled by the server, that stanza is the responsibility of the sender (e.g., to resend it or generate an error if it is never affirmed as handled by the server).</p>
<p>Receipt of an &lt;r/&gt; element does not imply that new stanzas have been transmitted by the peer; receipt of an &lt;a/&gt; element only indicates that new stanzas have been processed if the 'h' attribute has been incremented.</p>
<p>The value of 'h' starts at zero at the point stream management is enabled or requested to be enabled (see note below). The value of 'h' is then incremented to one for the first stanza handled and incremented by one again with each subsequent stanza handled. In the unlikely case that the number of stanzas handled during a stream management session exceeds the number of digits that can be represented by the unsignedInt datatype as specified in &w3xmlschema2; (i.e., 2<span class='super'>32</span>), the value of 'h' SHALL be reset from 2<span class='super'>32</span>-1 back to zero (rather than being incremented to 2<span class='super'>32</span>).</p>
<p class='box'>Note: There are two values of 'h' for any given stream: one maintained by the client to keep track of stanzas it has handled from the server, and one maintained by the server to keep track of stanzas it has handled from the client. The client initializes its value to zero when it sends &lt;enable/&gt; to the server, and the server initializes its value to zero when it receives &lt;enabled/&gt; from the client (it is expected that the server will respond immediately to &lt;enable/&gt; and set its counter to zero at that time). After this initialization, the client increments its value of 'h' for each stanza it handles from server, and the server increments its value of 'h' for each stanza it handles from the client.</p>
<p class='box'>Note: There are two values of 'h' for any given stream: one maintained by the client to keep track of stanzas it has handled from the server, and one maintained by the server to keep track of stanzas it has handled from the client. The client initializes its value to zero when it sends &lt;enable/&gt; to the server, and the server initializes its value to zero when it sends &lt;enabled/&gt; to the client (it is expected that the server will respond immediately to &lt;enable/&gt; and set its counter to zero at that time). After this initialization, the client increments its value of 'h' for each stanza it handles from server, and the server increments its value of 'h' for each stanza it handles from the client.</p>
<p>The following annotated example shows a message sent by the client, a request for acknowledgement, and an ack of the stanza.</p>
<example caption='Simple stanza acking'><![CDATA[
C: <enable xmlns='urn:xmpp:sm:3'/>
@ -578,7 +588,7 @@ S: <a h='10'/>
<xs:extension base='empty'>
<xs:attribute name='h'
type='xs:unsignedInt'
use='optional'/>
use='required'/>
<xs:attribute name='previd'
type='xs:string'
use='required'/>