<?xml version="1.0" encoding="US-ASCII"?>

<!-- used xml2rfc v2 -->
<!DOCTYPE rfc SYSTEM "rfc2629.dtd" [
<!ENTITY rfc2119 PUBLIC "" "http://xml.resource.org/public/rfc/bibxml/reference.RFC.2119.xml">
]>
<rfc number="7002" category="std" consensus="yes" submissionType="IETF"
     ipr="trust200902">
  <?xml-stylesheet type='text/xsl' href='rfc2629.xslt' ?>

  <?rfc toc="yes" ?>
  <?rfc symrefs="yes" ?>
  <?rfc sortrefs="yes"?>
  <?rfc rfcedstyle="yes" ?>
  <?rfc compact="yes" ?>
  <?rfc subcompact="no" ?>

  <front>
    <title abbrev="RTCP XR Discard">RTP Control Protocol (RTCP) Extended
    Report (XR) Block for&nbsp;Discard&nbsp;Count&nbsp;Metric&nbsp;Reporting</title>

    <author fullname="Alan Clark" initials="A." surname="Clark">
      <organization abbrev="Telchemy">Telchemy Incorporated</organization>

      <address>
        <postal>
          <street>2905 Premiere Parkway, Suite 280</street>

          <city>Duluth</city>

          <region>GA</region>

          <code>30097</code>

          <country>USA</country>
        </postal>

        <email>alan.d.clark@telchemy.com</email>
      </address>
    </author>

    <author fullname="Glen Zorn" initials="G." surname="Zorn">
      <organization>Network Zen</organization>

      <address>
        <postal>
          <street>227/358 Thanon Sanphawut</street>

          <city>Bang Na</city>

          <region>Bangkok</region>

          <code>10260</code>

          <country>Thailand</country>
        </postal>

        <phone>+66 (0) 8-1000-4155</phone>

        <email>glenzorn@gmail.com</email>
      </address>
    </author>

    <author fullname="Qin Wu" initials="Q." surname="Wu">
      <organization>Huawei</organization>

      <address>
        <postal>
          <street>101 Software Avenue, Yuhua District</street>

          <city>Nanjing</city>

          <region>Jiangsu</region>

          <code>210012</code>

          <country>China</country>
        </postal>

        <email>sunseawq@huawei.com</email>
      </address>
    </author>

    <date month="September" year="2013" />

    <area>Real-time Applications and Infrastructure Area</area>

    <workgroup>Audio/Video Transport Working Group</workgroup>

    <keyword>Real Time Control Protocol</keyword>

    <abstract>
      <t>This document defines an RTP Control Protocol (RTCP) Extended Report
      (XR) block that allows the reporting of a simple discard count metric
      for use in a range of RTP applications.</t>
    </abstract>
  </front>

  <middle>
    <section anchor="intro" title="Introduction">
      <section title="Discard Count Report Block">
        <t>This document defines a new block type to augment those defined in
        <xref target="RFC3611"></xref> for use in a range of RTP applications.
        The new block type supports the reporting of the number of packets
        that are received correctly but are never played out, typically
        because they arrive too late (buffer underflow) or
        too early (buffer overflow) to be played out. The metric is applicable both to systems
        that use packet loss repair techniques (such as forward error
        correction <xref target="RFC5109"></xref> or retransmission <xref
        target="RFC4588"></xref>) and to those that do not.</t>

        <t>This metric is useful for identifying the existence, and
        characterizing the severity, of packet transport problems that may
        affect users' perceptions of a service delivered over RTP.</t>

        <t>This block may be used in conjunction with <xref
        target="RFC7003"></xref>, which provides additional information on
        the pattern of discarded packets. However, the metric in <xref
        target="RFC7003"></xref> may be used independently of the metrics in
        this block.</t>

        <t>When a Discard Count Metrics Block is sent together with a Burst/Gap
        Discard Metrics Block (defined in <xref target="RFC7003"/>)
        to the media sender or RTP-based network management system, the
        information carried in the Discard Count Metrics Block and the Burst/Gap
        Discard Metrics Block allows systems receiving the blocks to
        calculate burst/gap summary statistics (e.g., the gap discard
        rate).</t>

        <t>The metric belongs to the class of transport-related end-system
        metrics defined in <xref target="RFC6792"></xref>.</t>
      </section>

      <section title="RTCP and RTCP Extended Reports">
        <t>The use of RTCP for reporting is defined in <xref
        target="RFC3550"></xref>. <xref target="RFC3611"></xref> defined an
        extensible structure for reporting using an RTCP Extended Report (XR).
        This document defines a new Extended Report block for use with <xref
        target="RFC3550"></xref> and <xref target="RFC3611"></xref>.</t>
      </section>

      <section title="Performance Metrics Framework">
        <t>"Guidelines for Considering New Performance Metric Development" <xref target="RFC6390"></xref>
        provides guidance on the definition and specification of performance
        metrics. "Guidelines for Use of the RTP Monitoring Framework" <xref
        target="RFC6792"></xref> provides guidance for reporting block format
        using RTCP XR. The metrics block described in this document is in
        accordance with the guidelines in <xref target="RFC6390"></xref> and
        <xref target="RFC6792"></xref>.</t>
      </section>

      <section title="Applicability" anchor="applicability">

        <t>This metric is believed to be applicable to a large class of RTP
        applications that use a de-jitter buffer <xref target="RFC5481"/>.</t>

        <t>Discards due to late or early arriving packets affect user
        experience. The reporting of discards alerts senders and other
        receivers to the need to adjust their transmission or reception
        strategies. The reports allow network managers to diagnose these user
        experience problems.</t>

        <t>The ability to detect duplicate packets can be used by managers to
        detect network layer or sender behavior, which may indicate network or
        device issues. Based on the reports, these issues may be addressed
        prior to any impact on user experience.</t>
      </section>
    </section>

    <section title="Terminology">
      
        <t>The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT",
        "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this
        document are to be interpreted as described in <xref
        target="RFC2119">RFC 2119</xref>.</t>

        <t>In addition, the following terms are defined:</t>

        <t><list style="hanging">
            <t hangText="Received, Lost, and Discarded"><vspace
            blankLines="1" />A packet shall be regarded as lost if it fails to
            arrive within an implementation-specific time window. A packet
            that arrives within this time window but is either too early or too late 
	    to be played out or is thrown away before
            playout due to packet duplication or redundancy shall be regarded
            as discarded. A packet shall not be regarded as discarded if it
            arrives within this time window but is dropped during decoding by
            some higher layer decoder, e.g., due to a decoding error. A packet
            shall be classified as one of the following: received (or OK), discarded, or lost.
            The discard count metric counts only discarded packets. The metric
            "cumulative number of packets lost" defined in <xref
            target="RFC3550"></xref> reports a count of packets lost from the
            media stream (single synchronization source (SSRC) within a single
            RTP session). Similarly, the metric "number of packets discarded"
            reports a count of packets discarded from the media stream (single
            SSRC within a single RTP session) arriving at the receiver. Another
            metric defined in <xref target="RFC5725"></xref> is available to
            report on packets that are not recovered by any repair techniques
            that may be in use. </t>
          </list></t>
      </section>
   

    <section title="Discard Count Metrics Block" anchor="DCMB">
      <t>Metrics in this block report on the number of packets discarded in
      the stream arriving at the RTP end system. The measurement of these
      metrics is made at the receiving end of the RTP stream. 

  Instances of this metrics block use the SSRC
  to refer to the separate auxiliary Measurement Information Block
  <xref target="RFC6776"/>, which describes measurement periods in use
  (see <xref target="RFC6776"/>, Section 4.2). 

      This metrics block relies on the
      measurement interval in the Measurement Information Block indicating the
      span of the report and MUST be sent in the same compound RTCP packet as
      the Measurement Information Block. If the measurement interval is not
      received in the same compound RTCP packet as this metrics block, this
      metrics block MUST be discarded.</t>

      <section title="Report Block Structure">
        <t>
The structure of the Discard Count Metrics Block is as follows.

<figure title="Figure 1: Report Block Structure">
            <artwork>
 0                   1                   2                   3
 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 2 3 4 5 6 7 8 9 0 1 
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|     BT=24     | I |DT |  resv |      Block Length = 2         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                        SSRC of Source                         |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
|                        Discard Count                          |
+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+
</artwork>
          </figure></t>
      </section>

      <section title="Definition of Fields in the Discard Count Metrics Block" anchor="def_of_fields">
        <t><list style="hanging">
            <t hangText="Block Type (BT): 8 bits"><vspace blankLines="1" />A
            Discard Count Metrics Block is identified by the constant
            24.<vspace blankLines="1" /></t>

            <t hangText="Interval Metric flag (I): 2 bits"><vspace
            blankLines="1" />This field indicates whether the reported metric
            is an Interval, Cumulative, or Sampled metric <xref
            target="RFC6792"></xref>: <list>
                <t>I=10: Interval Duration - the reported value applies to the
                most recent measurement interval duration between successive
                metrics reports.</t>

                <t>I=11: Cumulative Duration - the reported value applies to
                the accumulation period characteristic of cumulative
                measurements.</t>

                <t>I=01: Sampled Value - the reported value is a sampled
                instantaneous value.</t>
              </list>In this document, the discard count metric can only be
            measured over definite intervals and cannot be sampled.
            Accordingly, the value I=01, indicating a sampled value, MUST NOT
            be sent, and MUST be discarded when received. In addition, the
            value I=00 is reserved and also MUST NOT be sent, and MUST be
            discarded when received. <vspace blankLines="1" /></t>

            <t hangText="Discard Type (DT): 2 bits"><vspace
            blankLines="1" />This field is used to identify the discard type
            used in this report block. The discard type is defined as
            follows:<list>
                <t>00: Report packet discarded or being thrown away before
                playout due to packet duplication.</t>

                <t>01: Report packet discarded due to too early to be played
                out.</t>

                <t>10: Report packet discarded due to too late to be played
                out.</t>
              </list><vspace blankLines="1" />The value DT=11 is reserved for
            future definition and MUST NOT be sent, and MUST be discarded when
            received.<vspace blankLines="1" />An endpoint MAY report any
            combination of discard types in each reporting interval by
            including several Discard Count Metrics Blocks in a single
            RTCP XR packet.<vspace blankLines="1" />Some systems send
            duplicate RTP packets for robustness or error resilience. This is
            NOT RECOMMENDED since it breaks RTCP packet statistics. If
            duplication is desired for error resilience, the mechanism
            described in <xref target="RTPDUP"></xref> can be used, since this
            will not cause breakage of RTP streams or RTCP statistics.<vspace
            blankLines="1" /></t>

            <t hangText="Reserved (resv): 4 bits"><vspace
            blankLines="1" />These bits are reserved. They MUST be set to zero
            by senders and ignored by receivers (see <xref target="RFC6709"/>, Section 4.2).
            <vspace blankLines="1" /></t>

            <t hangText="Block Length: 16 bits"><vspace blankLines="1" />The
            length of this report block in 32-bit words, minus one, in
            accordance with the definition in <xref target="RFC3611"></xref>.
            This field MUST be set to 2 to match the fixed length of the
            report block. The block MUST be discarded if the block length is
            set to a different value. <vspace blankLines="1" /></t>

            <t hangText="SSRC of Source: 32 bits"><vspace blankLines="1" />As
            defined in Section 4.1 of <xref target="RFC3611"></xref>.<vspace
            blankLines="1" /></t>

            <t hangText="Discard Count"><vspace blankLines="1" />Number of
            packets discarded over the period (Interval or Cumulative) covered
            by this report. <vspace blankLines="1" />The measured value is
            an unsigned value. If the measured value exceeds 0xFFFFFFFD, the
            value 0xFFFFFFFE MUST be reported to indicate an over-range
            measurement. If the measurement is unavailable, the value
            0xFFFFFFFF MUST be reported. <vspace blankLines="1" />Note that
            the number of packets expected in the period associated with this
            metric (whether Interval or Cumulative) is available from the
            difference between a pair of extended sequence numbers in the
            Measurement Information Block <xref target="RFC6776"></xref>, so
            it need not be repeated in this block. <vspace blankLines="1" /></t>
          </list></t>
      </section>
    </section>

    <section title="SDP Signaling">
      <t><xref target="RFC3611"/> defines the use of the Session Description Protocol (SDP) <xref
      target="RFC4566"></xref> for signaling the use of XR blocks. However, XR
      blocks MAY be used without prior signaling (see Section 5 of RFC 3611).</t>

      <section title="SDP rtcp-xr Attribute Extension">
        <t>This section augments the SDP <xref target="RFC4566"></xref>
        attribute "rtcp-xr" defined in <xref target="RFC3611"></xref> by
        providing an additional value of "xr-format" to signal the use of the
        report block defined in this document. The ABNF <xref target="RFC5234"
/> syntax is as follows.<figure>
            <artwork>
xr-format =/ xr-pdc-block
xr-pdc-block = "pkt-discard-count"
</artwork></figure></t>
      </section>

      <section title="Offer/Answer Usage">
        <t>When SDP is used in Offer/Answer context, the SDP Offer/Answer
        usage defined in <xref target="RFC3611"></xref> for unilateral
        "rtcp-xr" attribute parameters applies. For detailed usage of
        Offer/Answer for unilateral parameters, refer to Section 5.2 of <xref
        target="RFC3611"></xref>.</t>
      </section>
    </section>

    <section title="IANA Considerations">
      <t>New block types for RTCP XR are subject to IANA registration. For
      general guidelines on IANA considerations for RTCP XR, refer to <xref
      target="RFC3611"></xref>.</t>

      <section title="New RTCP XR Block Type Value">
        <t>This document assigns the block type value 24 in the IANA "RTP
        Control Protocol Extended Reports (RTCP XR) Block Type Registry" to
        the "Discard Count Metrics Block".</t>
      </section>

      <section title="New RTCP XR SDP Parameter">
        <t>This document also registers a new parameter "pkt-discard-count" in
        the "RTP Control Protocol Extended Reports (RTCP XR) Session
        Description Protocol (SDP) Parameters Registry".</t>
      </section>

      <section title="Contact Information for Registrations">
        <t>The following contact information is provided for all registrations
        in this document:<figure>
            <artwork>
Qin Wu (sunseawq@huawei.com)
101 Software Avenue, Yuhua District
Nanjing, Jiangsu  210012
China
</artwork></figure></t>
      </section>
    </section>

    <section title="Security Considerations">
      <t>In some situations, returning very detailed error information
      (e.g., over-range measurement or measurement unavailable) using this
      report block can provide an attacker with insight into the security
      processing. Where this is a concern, the implementation should apply
      encryption and authentication to this report block. 

      For example, this can be achieved by using the
      Audio-Visual Profile with Feedback (AVPF) profile together with the
Secure RTP profile, as defined in <xref target="RFC3711"/>; an appropriate combination of those two
      profiles ("SAVPF") is specified in <xref target="RFC5124"/>.</t>

      <t>Besides this, it is believed that this RTCP XR block
      introduces no new security considerations beyond those described in
      <xref target="RFC3611"></xref>. This block does not provide per-packet
      statistics, so the risk to confidentiality documented in Section 7,
      paragraph 3 of <xref target="RFC3611"></xref> does not apply.</t>
    </section>

    <section title="Contributors">
      <t>Geoff Hunt wrote the initial draft of this document.</t>
    </section>

    <section title="Acknowledgments">
      <t>The authors gratefully acknowledge reviews and feedback provided by
Bruce Adams, 
Philip Arden, 
Amit Arora, 
Claire Bi,
Bob Biskner,
Gonzalo Camarillo,
Benoit Claise,
Kevin Connor,
Claus Dahm,
Spencer Dawkins,
Randy Ethier,
Roni Even,
Stephen Farrel,
Jim Frauenthal,
Kevin Gross,
Albert Higashi,
Tom Hock,
Shane Holthaus,
Paul Jones,
Rajesh Kumar,
Keith Lantz,
Jonathan Lennox,
Mohamed Mostafa,
Amy Pendleton,
Colin Perkins,
Mike Ramalho,
Ravi Raviraj,
Dan Romascanu,
Albrecht Schwarz,
Varun Singh,
Tom Taylor,
Dan Wing,
and Hideaki Yamada.</t>
    </section>
  </middle>

  <back>
    <references title="Normative References">
     
 <?rfc include="reference.RFC.2119" ?>
 <?rfc include="reference.RFC.3611" ?>
 <?rfc include="reference.RFC.4566" ?>
 <?rfc include="reference.RFC.3550" ?>
 <?rfc include="reference.RFC.5234" ?>
 <?rfc include="reference.RFC.6776" ?>
 <?rfc include="reference.RFC.6709" ?>
 <?rfc include="reference.RFC.3711" ?>
 <?rfc include="reference.RFC.5124" ?>

    </references>

    <references title="Informative References">
      
 <?rfc include="reference.RFC.5481" ?>
 <?rfc include="reference.RFC.4588" ?>
 <?rfc include="reference.RFC.5109" ?>
 <?rfc include="reference.RFC.5725" ?>
 <?rfc include="reference.RFC.6390" ?>
 <?rfc include="reference.RFC.6792" ?>


<!-- draft-ietf-xrblock-rtcp-xr-burst-gap-discard-14: RFC-to-be 7003 -->
      <reference anchor="RFC7003">

<front>
<title>RTP Control Protocol(RTCP) Extended Report (XR) Block for Burst/Gap Discard Metric Reporting</title>

<author initials='A' surname='Clark' fullname='Alan Clark'>
    <organization />
</author>

<author initials='R' surname='Huang' fullname='Rachel Huang'>
    <organization />
</author>

<author initials='Q' surname='Wu' fullname='Qin Wu' role='editor'>
    <organization />
</author>

          <date month="September" year="2013" />
        </front>

        <seriesInfo name="RFC"
                    value="7003" />

      </reference>

<!-- draft-ietf-avtext-rtp-duplication-02, Active -->
      <reference anchor="RTPDUP">
        <front>
          <title>Duplicating RTP Streams</title>

          <author fullname="Ali Begen " initials="A." surname="Begen">
            <organization></organization>
          </author>

          <author fullname="Colin Perkins" initials="C." surname="Perkins">
            <organization></organization>
          </author>

          <date month="March" year="2013" />
        </front>

        <seriesInfo name="Work in" value="Progress" />

      </reference>

     
    </references>

    <section title="Metrics Represented Using the Template from RFC 6390">

      <t><list style="letters">
          <t>Number of Packets Discarded Metric<list
              style="symbols">
              <t>Metric Name: Number of RTP packets discarded.</t>

              <t>Metric Description: Number of RTP packets discarded over the
              period covered by this report.</t>

              <t>Method of Measurement or Calculation: See <xref
target="def_of_fields"/>, Discard Count definition.</t>

              <t>Units of Measurement: See <xref target="def_of_fields"/>,
Discard Count definition.</t>

              <t>Measurement Point(s) with Potential Measurement Domain: See
              <xref target="DCMB"/>, 1st paragraph. </t>

              <t>Measurement Timing: See <xref target="DCMB"/>, 1st paragraph
              for measurement timing and <xref target="def_of_fields"/> for Interval
              Metric flag. </t>

              <t>Use and Applications: See <xref target="applicability"/>.</t>

              <t>Reporting Model: See RFC 3611.</t>
            </list></t>
        </list></t>
    </section>

  </back>
</rfc>
