Commit Graph

17 Commits

Author SHA1 Message Date
Tim Burke d496d03b7f api-ref: Document `reverse` param
Change-Id: I731ff275e14fbb0271ddb50f91550197d6d0a4a4
2022-04-07 12:45:07 -07:00
Tim Burke 33792353fc api-ref: Clean up container and object response code formatting
Change-Id: I994ea0c9700678ab7e1364badc2ff88ebef5ec5e
Closes-Bug: #1806596
2018-12-05 19:30:41 +00:00
Robert Francis 99b89aea10 Symlink implementation.
Add a symbolic link ("symlink") object support to Swift. This
object will reference another object. GET and HEAD
requests for a symlink object will operate on the referenced object.
DELETE and PUT requests for a symlink object will operate on the
symlink object, not the referenced object, and will delete or
overwrite it, respectively.
POST requests are *not* forwarded to the referenced object and should
be sent directly. POST requests sent to a symlink object will
result in a 307 Error.

Historical information on symlink design can be found here:
https://github.com/openstack/swift-specs/blob/master/specs/in_progress/symlinks.rst.
https://etherpad.openstack.org/p/swift_symlinks

Co-Authored-By: Thiago da Silva <thiago@redhat.com>
Co-Authored-By: Janie Richling <jrichli@us.ibm.com>
Co-Authored-By: Kazuhiro MIYAHARA <miyahara.kazuhiro@lab.ntt.co.jp>
Co-Authored-By: Kota Tsuyuzaki <tsuyuzaki.kota@lab.ntt.co.jp>

Change-Id: I838ed71bacb3e33916db8dd42c7880d5bb9f8e18
Signed-off-by: Thiago da Silva <thiago@redhat.com>
2017-12-13 21:26:12 +00:00
Tim Burke c6d00fe22f api-ref: Fix container PUT response codes
Change-Id: I7b57b6ee7095105399518873f8ae59da63cd8ce5
Closes-Bug: #1549411
2017-09-11 15:03:12 +00:00
Jenkins 9fbda9946e Merge "Unify 'Content-Type' header key name in API reference" 2017-09-06 19:07:33 +00:00
Kazuhiro MIYAHARA 9fd9141f7d Unify 'Content-Type' header key name in API reference
In current API reference, 'Content-Type' header key name is used in response
parameter tables except Container GET table. On the other hand, 'Content_Type'
is used in Container GET table.

This patch fixes the 'Content_Type' in Container GET table to 'Content-Type'.

Change-Id: Idf242477dd089202635b69b85b0c19739e0c6321
2017-09-06 11:06:26 +00:00
Kazuhiro MIYAHARA 275da4c18e Fix bytes and name API reference of Container GET
In current API reference, 'bytes' and 'name' descriptions of Container GET are
shared with Account GET. However, the descriptions are not correct for
Container GET.

This patch separate descriptions for Container GET and descriptions for Account
GET and fix descriptions for Container GET.

Change-Id: Ibedd08c5d9ebe145caf567edbd9757d7bc83b96d
2017-09-06 04:16:40 +00:00
Tim Burke 9f5aa3bbd7 api-ref: update docs links
Change-Id: I83da881f82faf340d0e394c79f7e9d4df7f34b04
2017-08-31 15:57:13 -07:00
Janie Richling 8e122c6fe8 Document X-Openstack-Request-Id in all responses
Swift returns `X-Openstack-Request-Id` for container and
object requests as well as account.  A couple api-ref docs are
missing this value in the response examples.

Change-Id: Ifcd67a620e04be5e92b43c7749ee4acb50bb171d
2016-11-15 13:15:59 -06:00
Jenkins f1c3ceb48d Merge "Use separate headers for versioned_writes' stack and history modes" 2016-09-22 20:05:02 +00:00
Tim Burke 60a2fe0ba8 Use separate headers for versioned_writes' stack and history modes
Now, instead of saying

   X-Versions-Location: <container>
   X-Versions-Mode: history

clients should just say

   X-History-Location: <container>

Since we've never had a release featuring a user-settable
X-Versions-Mode header, support may be dropped and that is now ignored.

Change-Id: Icfd0f481d4e40dd5375c737190aea7ee8dbc3bf9
2016-09-21 16:42:27 -07:00
Jenkins e07f9be8f5 Merge "api-ref: fix some header definitions" 2016-09-21 06:44:27 +00:00
Alistair Coles cbfa79a159 api-ref: fix some header definitions
Clarify Content-Type header definition for listings.

Distinguish between request and response definitions for
X-Account-Meta-Temp-URL-Key* headers.

Insert X-Container-Meta-Quota-* headers missing from some
request/response definitions.

Improve X-Container-Meta-Access-Control-Expose-Headers
parameter formatting.

Distinguish between request and response definitions for
X-Container-Meta-Temp-URL-Key* headers.

Co-Authored-By: Christian Schwede <cschwede@redhat.com>
Change-Id: I8fc7610395973b520aa9ddd72c94e1eb75f602cd
Related-Change: I315b4e550b7d10880fbc00fce9311127ba609c2d
2016-09-20 14:30:27 +01:00
Alistair Coles 2355771d4b api-ref: Move repeated paragraph to an include file
Move repeated test re metadata header syntax to an include
file and make it be rendered as a note.

Also make already included text about metadata header value
encoding be a note.

Change-Id: I4795836587492954ad24dd5baaa5d668746d6040
2016-09-19 09:18:19 +01:00
Donagh McCabe 9ce596a5a6 Corrections for the API specifications in api-ref
Fixes a number of technical issues with the api-ref section
including:

- Added missing headers
- The header descriptions were made specific to whether they
  are used in requests or responses and the verb in question
  (example: Content-Length in object HEAD is the object size,
  not the response body length).
- Added references to API features such as bulk delete.
- Many typographical fixes (e.g., spaces in the middle
  of header names)
- Restored xml and json account/container listing
  examples.

The following areas were not updated and it is proposed
to defer them to a subsequent update. This is because
I don't have time or their merit is debatable:

- ACLs (as used in a Keystone context) are not
  described.
- Account create/delete is not described.
- I left List Endpoints as-is.

Change-Id: I315b4e550b7d10880fbc00fce9311127ba609c2d
2016-09-14 10:10:20 +01:00
Tim Burke c7283be4fe Add "history" mode to versioned_writes middleware
This change introduces the concept of a "versioning mode" for
versioned_writes. The following modes are supported:

 * stack

    When deleting, check whether any previous versions exist in the
    versions container. If none is found, the object is deleted. If the
    most-recent version in the versions container is not a delete
    marker, it is copied into the versioned container (overwriting the
    current version if one exists) and then deleted from the versions
    container. This preserves the previous behavior.

    If the most-recent version in the versions container is a delete
    marker and a current version exists in the versioned container, the
    current version is deleted. If the most-recent version in the
    versions container is a delete marker and no current version exists
    in the versioned container, we copy the next-most-recent version
    from the versions container into the versioned container (assuming
    it exists and is not a delete marker) and delete both the
    most-recent version (i.e., the delete marker) and the just-copied
    next-most-recent version from the versions container.

    With this mode, DELETEs to versioned containers "undo" operations
    on containers. Previously this was limited to undoing PUTs, but now
    it will also undo DELETEs performed while in "history" mode.

 * history

    When deleting, check whether a current version exists in the
    versioned container. If one is found, it is copied to the versions
    container. Then an empty "delete marker" object is also put into the
    versions container; this records when the object was deleted.
    Finally, the original current version is deleted from the versioned
    container. As a result, subsequent GETs or HEADs will return a 404,
    and container listings for the versioned container do not include
    the object.

    With this mode, DELETEs to versioned containers behave like DELETEs
    to other containers, but with a history of what has happened.

Clients may specify (via a new X-Versions-Mode header) which mode a
container should use. By default, the existing "stack" mode is used.

Upgrade consideration:
======================

Clients should not use the "history" mode until all proxies in the
cluster have been upgraded. Attempting to use the "history" mode during
a rolling upgrade may result in some requests being served by proxies
running old code (which necessarily uses the "stack" mode), leading to
data loss.

Change-Id: I555dc17fefd0aa9ade681aa156da24e018ebe74b
2016-08-15 21:04:29 -07:00
Cloud User 4b13879680 Adds migrated API reference files
This brings in RST plus YAML files, migrated from the source for [0].

The migration explanation is found on the openstack-dev mailing list [1].

Project instruction is in the OpenStack Documentation Contributor Guide [2].

A patch for publishing this source is in [3].

The conf.py and the tox environment are standard across other projects.

[0]http://developer.openstack.org/api-ref-objectstorage-v1.html
[1]http://lists.openstack.org/pipermail/openstack-dev/2016-May/093765.html
[2]http://docs.openstack.org/contributor-guide/api-guides.html
[3]https://review.openstack.org/#/c/313015/

Change-Id: Ifebc65b188c4f2ba35b61c0deae5ec24401df7f9
2016-06-21 19:14:22 +02:00