datatracker.ietf.org
Sign in
Version 5.6.2.p5, 2014-08-04
Report a bug

A Media Type for XML Patch Operations
RFC 7351

Document type: RFC - Informational (August 2014; No errata)
Was draft-wilde-xml-patch (individual)
Document stream: ISE
Last updated: 2014-08-13
Other versions: plain text, pdf, html
IETF Conflict Review: conflict-review-wilde-xml-patch

ISE State: Published RFC
Document shepherd: Nevil Brownlee
Shepherd Write-Up: Last changed 2014-06-12

IESG State: RFC 7351 (Informational)
IANA Review State: IANA OK - Actions Needed
IANA Action State: RFC-Ed-Ack
Responsible AD: (None)
Send notices to: No addresses provided

Independent Submission                                          E. Wilde
Request for Comments: 7351                                   UC Berkeley
Category: Informational                                      August 2014
ISSN: 2070-1721

                 A Media Type for XML Patch Operations

Abstract

   The XML patch document format defines an XML document structure for
   expressing a sequence of patch operations to be applied to an XML
   document.  The XML patch document format builds on the foundations
   defined in RFC 5261.  This specification also provides the media type
   registration "application/xml-patch+xml", to allow the use of XML
   patch documents in, for example, HTTP conversations.

Status of This Memo

   This document is not an Internet Standards Track specification; it is
   published for informational purposes.

   This is a contribution to the RFC Series, independently of any other
   RFC stream.  The RFC Editor has chosen to publish this document at
   its discretion and makes no statement about its value for
   implementation or deployment.  Documents approved for publication by
   the RFC Editor are not a candidate for any level of Internet
   Standard; see Section 2 of RFC 5741.

   Information about the current status of this document, any errata,
   and how to provide feedback on it may be obtained at
   http://www.rfc-editor.org/info/rfc7351.

Copyright Notice

   Copyright (c) 2014 IETF Trust and the persons identified as the
   document authors.  All rights reserved.

   This document is subject to BCP 78 and the IETF Trust's Legal
   Provisions Relating to IETF Documents
   (http://trustee.ietf.org/license-info) in effect on the date of
   publication of this document.  Please review these documents
   carefully, as they describe your rights and restrictions with respect
   to this document.

Wilde                         Informational                     [Page 1]
RFC 7351                        XML Patch                    August 2014

Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . .   2
   2.  Patch Documents . . . . . . . . . . . . . . . . . . . . . . .   3
     2.1.  Patch Document Format . . . . . . . . . . . . . . . . . .   3
     2.2.  Patch Examples  . . . . . . . . . . . . . . . . . . . . .   5
   3.  IANA Considerations . . . . . . . . . . . . . . . . . . . . .   5
   4.  Security Considerations . . . . . . . . . . . . . . . . . . .   7
   5.  Acknowledgements  . . . . . . . . . . . . . . . . . . . . . .   7
   6.  References  . . . . . . . . . . . . . . . . . . . . . . . . .   7
     6.1.  Normative References  . . . . . . . . . . . . . . . . . .   7
     6.2.  Informative References  . . . . . . . . . . . . . . . . .   7
   Appendix A.  Implementation Hints . . . . . . . . . . . . . . . .   9
     A.1.  Matching Namespaces . . . . . . . . . . . . . . . . . . .   9
     A.2.  Patching Namespaces . . . . . . . . . . . . . . . . . . .  10
   Appendix B.  ABNF for RFC 5261  . . . . . . . . . . . . . . . . .  12

1.  Introduction

   The Extensible Markup Language (XML) [RFC7303] is a common format for
   the exchange and storage of structured data.  HTTP PATCH [RFC5789]
   extends HTTP [RFC7231] with a method to perform partial modifications
   to resources.  HTTP PATCH requires that patch documents be sent along
   with the request, and it is therefore useful for there to be
   standardized patch document formats (identified by media types) for
   popular media types.

   The XML patch media type "application/xml-patch+xml" is an XML
   document structure for expressing a sequence of operations to apply
   to a target XML document, suitable for use with the HTTP PATCH
   method.  Servers can freely choose which patch formats they want to
   accept, and "application/xml-patch+xml" could be a simple default
   format that can be used unless a server decides to use a different
   (maybe more sophisticated) patch format for XML.

   The format for patch documents is based on the XML patch framework
   defined in RFC 5261 [RFC5261].  While RFC 5261 does define a concrete
   syntax as well as the media type "application/patch-ops-error+xml"
   for error documents, it only defines XML Schema (XSD)
   [W3C.REC-xmlschema-1-20041028] types for patch operations.  The
   concrete document format and the media type for patch operations are
   defined in an XSD defined in this specification.

   This specification relies on RFC 5261 but also requires that errata
   reported to date are taken into account.  The main reason for the
   errata is the problematic ways in which RFC 5261 relies on XML Path
   Language (XPath) as the expression language for selecting the
   location of a patch, while at the same time XPath's data model does

[include full document text]