deb-manila/api-ref/source/share-servers.inc
Daniel Gonzalez 3e86e3deac Migrate API reference into tree
The API Documentation team has requires [1] that
projects maintain their api-reference in-tree and
build it to the developer.openstack.org website.

This version of the API reference uses os-api-ref
and compiles API documentation close to that of
the OpenStack compute service (nova).

Co-Authored-By: Goutham Pacha Ravi <gouthamr@netapp.com>

[0] http://lists.openstack.org/pipermail/openstack-dev/2016-May/093765.html

Implements: bp move-manila-api-reference-in-tree
Change-Id: I67bb3354162d6e0e00fa2788edde864cc14920ee
2016-07-25 15:55:00 +00:00

142 lines
3.9 KiB
ReStructuredText

.. -*- rst -*-
=============
Share servers
=============
A share server is created by multi-tenant back-end drivers where
shares are hosted. For example, with the ``generic`` driver, shares
are hosted on Compute VMs.
Administrators can perform read and delete actions for share
servers. An administrator can delete an active share server only if
it contains no dependent shares. If an administrator deletes the
share server, the Shared File Systems service creates a share
server in response to a subsequent create share request.
An administrator can use the ``policy.json`` file to grant
permissions for share server actions to other roles.
The status of a share server indicates its current state. After you
successfully set up a share server, its status is ``active``. If
errors occur during set up such as when server data is not valid,
its status is ``error``.
The possible share servers statuses are:
**Share server statuses**
+--------------+------------------------------------------------------------------+
| Status | Description |
+--------------+------------------------------------------------------------------+
| ``active`` | Share server was successfully set up. |
+--------------+------------------------------------------------------------------+
| ``error`` | The set up or deletion of the share server failed. |
+--------------+------------------------------------------------------------------+
| ``deleting`` | The share server has no dependent shares and is being deleted. |
+--------------+------------------------------------------------------------------+
| ``creating`` | The share server is being created on the back end with data from |
| | the database. |
+--------------+------------------------------------------------------------------+
List share servers
==================
.. rest_method:: GET /v2/{tenant_id}/share-servers
Lists all share servers.
Normal response codes: 200
Error response codes: badRequest(400), unauthorized(401), forbidden(403)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
Response parameters
-------------------
.. rest_parameters:: parameters.yaml
- id: id_14
- project_id: project_id_7
- status: status_15
- share_network_id: share_network_id
- share_network_name: share_network_name
- host: host_8
- updated_at: updated_at_6
Response example
----------------
.. literalinclude:: samples/share-servers-list-response.json
:language: javascript
Show share server details
=========================
.. rest_method:: GET /v2/{tenant_id}/share-servers/{share_server_id}/detail
Shows details for a share server.
Normal response codes: 200
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
itemNotFound(404)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
- share_server_id: share_server_id
Response parameters
-------------------
.. rest_parameters:: parameters.yaml
- id: id_14
- project_id: project_id_7
- status: status_15
- backend_details: backend_details
- share_network_id: share_network_id_6
- share_network_name: share_network_name
- host: host_8
- created_at: created_at_11
- updated_at: updated_at_6
Response example
----------------
.. literalinclude:: samples/share-server-show-details-response.json
:language: javascript
Delete share server
===================
.. rest_method:: DELETE /v2/{tenant_id}/share-servers/{share_server_id}
Deletes a share server.
An administrator can delete an active share server only if it
contains no dependent shares.
Normal response codes: 202
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
itemNotFound(404), conflict(409)
Request
-------
.. rest_parameters:: parameters.yaml
- tenant_id: tenant_id_1
- share_server_id: share_server_id