[Docs] [txt|pdf] [Tracker] [Email] [Nits]

Versions: 00 01 02 03 04 05 06 07

Individual Submission                                    T. Harding, Ed.
Internet-Draft                                                     Axway
Intended status: Informational                              October 2009
Expires: April 4, 2010


                  AS2 Restart for Very Large Messages
                      draft-harding-as2-restart-00

Status of this Memo

   This Internet-Draft is submitted to IETF in full conformance with the
   provisions of BCP 78 and BCP 79.

   Internet-Drafts are working documents of the Internet Engineering
   Task Force (IETF), its areas, and its working groups.  Note that
   other groups may also distribute working documents as Internet-
   Drafts.

   Internet-Drafts are draft documents valid for a maximum of six months
   and may be updated, replaced, or obsoleted by other documents at any
   time.  It is inappropriate to use Internet-Drafts as reference
   material or to cite them other than as "work in progress."

   The list of current Internet-Drafts can be accessed at
   http://www.ietf.org/ietf/1id-abstracts.txt.

   The list of Internet-Draft Shadow Directories can be accessed at
   http://www.ietf.org/shadow.html.

   This Internet-Draft will expire on April 4, 2010.

Copyright Notice

   Copyright (c) 2009 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 in effect on the date of
   publication of this document (http://trustee.ietf.org/license-info).
   Please review these documents carefully, as they describe your rights
   and restrictions with respect to this document.

Abstract

   AS2 Restart provides a method for AS2 clients and servers to restart
   payload transfers from the point of failure without requiring the
   entire document to be resent.



Harding                   Expires April 4, 2010                 [Page 1]


Internet-Draft              Abbreviated Title               October 2009


Table of Contents

   1.  Introduction  . . . . . . . . . . . . . . . . . . . . . . . . . 3
   2.  Overview  . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
   3.  Protocol  . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
     3.1.  Transfer ID . . . . . . . . . . . . . . . . . . . . . . . . 3
     3.2.  HEAD Query  . . . . . . . . . . . . . . . . . . . . . . . . 3
     3.3.  POST  . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
   4.  Important Considerations  . . . . . . . . . . . . . . . . . . . 5
   5.  Example Messages  . . . . . . . . . . . . . . . . . . . . . . . 5
     5.1.  Initial Send  . . . . . . . . . . . . . . . . . . . . . . . 5
     5.2.  Restart . . . . . . . . . . . . . . . . . . . . . . . . . . 6
   6.  IANA Considerations . . . . . . . . . . . . . . . . . . . . . . 7
   7.  Security Considerations . . . . . . . . . . . . . . . . . . . . 7
   8.  Normative References  . . . . . . . . . . . . . . . . . . . . . 7
   Author's Address  . . . . . . . . . . . . . . . . . . . . . . . . . 7



































Harding                   Expires April 4, 2010                 [Page 2]


Internet-Draft              Abbreviated Title               October 2009


1.  Introduction

   AS2 [RFC4130] has experienced widespread adoption and is continually
   being asked to send or receive larger files by the business community
   between its trading partners.  As the size of the file transfers
   increase it has become evident that a mechanism is required that will
   allow trading partners to restart failed transfers from the point of
   failure.  This document will outline a method of implementing a
   failed transfer restart mechamism using existing HTTP headers so
   backwards compatibilty will exist with AS2 servers not wishing to
   support AS2 Restart.


2.  Overview

   Clients wishing to utilize the AS2 Restart mechanism for a particular
   file transfer will include the HTTP ETAG header which contains an
   unique transfer-id.  The message will also contain an HTTP Content-
   Range header indicating the start and end byte range of the message.
   The receiving HTTP server will utilize the ETAG and Content-Range
   headers to perform a temporary cache of the received file in the
   event of a transfer failure so a restart from the point of failure
   can occur.  A client can query a server using the HTTP HEAD request
   to determine the number of bytes of data already received by the
   server.  The HTTP Head request will contain an ETAG header with a
   unique transfer-id of a previous transfer.  The server will respond
   with a Content-length header value equalling the number of bytes
   already received from a previous transfer.


3.  Protocol

3.1.  Transfer ID

   The transfer id is a unique value that references a previous file
   transfer.  The uniqueness of the transfer id is guaranteed by the
   sending client and will reference only one instantiation of a
   particular file transfer.  The transfer id will follow the
   definitions of an entity tag as per [RFC2616] section 3.11 minus the
   weak indicator.

3.2.  HEAD Query

   The HEAD query will be used by the sending client to query a server
   as to the status of a previous file transfer.  The server will
   respond to the HEAD query with the number of bytes already received
   for a particular transfer-id value.  The returned Content-Length byte
   count is the number of bytes of the received content and does not



Harding                   Expires April 4, 2010                 [Page 3]


Internet-Draft              Abbreviated Title               October 2009


   include the http headers.  If the returned Content-Length value from
   the HEAD query equals the total instance value the sending system
   will send at least one byte of data in the next POST.  This will
   allow the client to restablish a network connection to the server
   while it waits for the appropriate response from the server.

                                HEAD Query

   +-------------+    +-------------------+    +-------------+
   | HTTP Client |--->| Etag: transfer id |--->| HTTP Server |
   |_____________|    |___________________|    |_____________|
       +                                           |
       |                                           |
       |    +---------------------------+          |
       -----| Response: 200 OK          |<---------
            | Content-Length: file size |
            |___________________________|


                                 Figure 1

   AS2 servers that do not understand the HEAD query or do not support
   AS2 Restart may return a non 200 ok response or return a Content-
   Length of zero.  In either case the client will (re)send the complete
   AS2 message to the server.

3.3.  POST

   A posted message will contain the ETAG header with an unique transfer
   id and a Content-Range header indicating the range of bytes contained
   within the message.  The Content-Range header value will be the range
   within the body of the message and does not include the http headers
   of the message.  A Content-Range header is not required if the
   sending client is sending a file for the first time or wishes to
   overwrite any existing data on the server.
















Harding                   Expires April 4, 2010                 [Page 4]


Internet-Draft              Abbreviated Title               October 2009


                                   POST

   +-------------+    +----------------------+    +-------------+
   | HTTP Client |--->| POST                 |    | HTTP Server |
   |             |    | Etag: transfer id    |--->|             |
   |             |    | Content-Range:       |    |             |
   |             |    |  bytes 0-1000/1001   |    |             |
   |_____________|    |______________________|    |_____________|
       +                                             |
       |                                             |
       |    +---------------------------+            |
       -----| Response: 200 OK          |<-----------
            |___________________________|


                                 Figure 2


4.  Important Considerations

   The HTTP restart server will be concerned with temp files bogging
   down the system disk space and should develop a routine to garbage
   collect any old (aged) files in the restart directory.  If a client
   queries the server about a existing file that was partially sent and
   the file was deleted due to aging from the system, the server will
   return a 200 ok response with a content-length of zero bytes.
   Therefore the client will be required to resend the complete message.

   The unique id mentioned earlier in this document must be unique so no
   two systems create the same id.


5.  Example Messages

5.1.  Initial Send

                               HEAD Command

   HEAD /exchange/axway1 HTTP/1.1\n
   Etag: ci1257348820455.829541_tharding_2k_te
   Connection: close
   Host: yourhost.com

   The HEAD request is used to query the server to determine if a
   partially transfered file exists on the server.






Harding                   Expires April 4, 2010                 [Page 5]


Internet-Draft              Abbreviated Title               October 2009


                                 Response

   HTTP/1.1 200 OK
   Connection: close
   Content-Length: 0

   The returned Content-Length value indicates the number of bytes
   associated with a specific transfer that resides on the server.  A
   returned Content-Length value of 0 indicates that the server does not
   have a partially saved file or the server does not support AS2
   restart.  In either case the sending system will send all bytes
   associated with a message.  Non 2xx http return codes will indicate
   that the receiving server does not support AS2 restart.

                               POST Command

   POST /exchange/axway1 HTTP/1/1
   <existing HTTP headers>
   Etag: ci1257348820455.829541_tharding_2k_te
   Content-Length: 307502443

   <Message body>

   The first time a file is sent to a server only the ETAG is required.
   The Content-Range header is not required because this is the first
   time this message has been sent to the server.  POSTed files without
   the ETAG header will not be saved to allow a restart if the transfer
   fails.

5.2.  Restart

                               HEAD Command

   HEAD /exchange/axway1 HTTP/1.1\n
   Etag: ci1257348820455.829541_tharding_2k_te
   Connection: close
   Host: yourhost.com

                                 Response

   HTTP/1.1 200 OK
   Connection: close
   Content-Length: 65982464

   The returned Content-Length value indicates the number of bytes of
   data already received from a previous send.  This value does not
   include the HTTP headers of the message but only the Content data.




Harding                   Expires April 4, 2010                 [Page 6]


Internet-Draft              Abbreviated Title               October 2009


                               POST Command

   POST /exchange/axway1 HTTP/1/1
   <existing HTTP headers>
   Etag: ci1257348820455.829541_tharding_2k_te
   Content-Range: bytes 65982464-307502442/307502443
   Content-Length: 241519979

   <Message body>

   A message that is being resent will indicate the starting byte of the
   content data by using the Content-Range header.  The Content-Range
   header value will indicate the first byte and the last byte of the
   message.


6.  IANA Considerations

   This memo includes no request to IANA.


7.  Security Considerations

   Refer to the Security Considerations section of AS2 [RFC4130].


8.  Normative References

   [RFC2616]  Fielding, R., Gettys, J., Mogul, J., Frystyk, H.,
              Masinter, L., Leach, P., and T. Berners-Lee, "Hypertext
              Transfer Protocol -- HTTP/1.1", RFC 2616, June 1999.

   [RFC4130]  Moberg, D. and R. Drummond, "MIME-Based Secure Peer-to-
              Peer Business Data Interchange Using HTTP, Applicability
              Statement 2 (AS2)", RFC 4130, July 2005.


Author's Address

   Terry Harding (editor)
   Axway
   Phoenix, Arizona  85054
   US

   Phone:
   Email: tharding@us.axway.com





Harding                   Expires April 4, 2010                 [Page 7]


Html markup produced by rfcmarkup 1.121, available from https://tools.ietf.org/tools/rfcmarkup/