16 Commits

Author SHA1 Message Date
zhangbailin
28c1075b59 Resource retrieving: add changes-before filter
This adds the changes-before filter to the servers,
os-instance-actions and os-migrations APIs for
filtering resources which were last updated before
or equal to the given time. The changes-before filter,
like the changes-since filter, will return deleted
server resources.

Part of bp support-to-query-nova-resources-filter-by-changes-before
Change-Id: If91c179e3823c8b0da744a9363906b0f7b05c326
2018-09-19 09:56:56 -04:00
Yikun Jiang
c2f7d65858 Add host/hostId to instance action events API
This patch adds a new microversion to
``GET /servers/{server_id}/os-instance-actions/{req_id}`` API to
include the ``host`` field for admin and an ``hostId`` for all users
by default. And the display of newly added ``host`` field will be
controlled by the same policy as the ``traceback`` field.

The newly added fields can be used to determine on which host a
given action event occurred.

Part of blueprint: add-host-to-instance-action-events

Change-Id: I2f8b4a12a088b9ed96b428eafde2e0c478fb1db5
2018-04-26 14:17:02 +00:00
Matt Riedemann
8e2000efc8 Clarify wording in listing instance actions for deleted instances
The ability to list instance actions for deleted servers was
added in the 2.21 microversion, so we should update the wording
to make that clear.

Change-Id: Ibf05d5bd2c70aa579bb2a688d4d5fa63278176d2
2018-02-26 10:31:52 -05:00
Takashi NATSUME
6f92e3906b api-ref: Fix incorrect parameter name
In os-instance-actions.inc,
the 'instance_actions_links' parameter should be 'links'
in the response of "GET /servers/{server_id}/os-instance-actions" API.

Change-Id: If333b6e063fe68c09706584890ae2753f1b7c84f
Closes-Bug: #1740107
2017-12-26 18:44:38 +09:00
Kevin_Zheng
0c480d795f Add pagination and changes-since for instance-actions
This patch adds pagination support and changes-since filter
for os-instance-actions API.

Users can now use 'limit' and 'marker' to perform paginate
query of instance action list. Users can also filter the
results according to the actions' updated time.

Co-Authored-By: Yikun Jiang <yikunkero@gmail.com>

Implement: blueprint pagination-add-changes-since-for-instance-action-list

Change-Id: I1a1b39803e8d0449f21d2ab5ef96d4060e638aa8
2017-12-14 07:42:17 +00:00
Mathieu Gagné
bbe0f313bd Add ability to signal and perform online volume size change
Allow Cinder to use external events to signal a volume extension.

1) Nova will then call os-brick to perform the volume extension
   so the host can detect its new size.
2) Compute driver will resize the device in QEMU so instance can detect
   the new disk size without rebooting.

This change:

* Adds the 'volume-extended' external event.
  The event tag needs to be the extended volume id.
* Bumps the latest microversion to 2.51.
* Exposes non-traceback instance action event details for
  non-admins on the microversion. This is needed for the
  non-admin API user that initiated the volume extend
  operation to be able to tell when the nova-compute side
  is complete.

Co-Authored-By: Matt Riedemann <mriedem.os@gmail.com>

Blueprint: nova-support-attached-volume-extend

Change-Id: If10cffd0dc4c9879f6754ce39bee5fae1d04f474
2017-07-12 11:53:20 -04:00
Matt Riedemann
d2d84eb102 api-ref: mark instance action events parameter as optional
For "GET /servers/{server_id}/os-instance-actions/{request_id}",
the "events" parameter in the response body is only included by
default policy for administrators. You can get details if you're
an admin or own the server, but the events are only returned for
admins by default.

This change does two things:

1. Fixes the description of the default policy since admin or
   owner can get action details for a particular request.
2. Fixes the "events" parameter description by pointing out it
   is optional and only returned by default for admins.

Change-Id: I6410a0aac223133d8d07fd65c268553ebb9e7e67
Closes-Bug: #1702573
2017-07-12 10:56:13 -04:00
Kevin_Zheng
974535bacf Complete verification of os-instance-actions.inc
This patch verifies the examples and body of
os-instance-actions.inc

part of bp:api-ref-in-rst

Change-Id: I271629553c6705f9cce74a23b8335c2fd23e9f09
2016-07-26 02:53:42 +00:00
Kevin_Zheng
f6ef9b4b28 Parameter verification of os-instance-actions.inc
This patch verifies the parameters of
os-instance-actions.inc

part of bp:api-ref-in-rst

Change-Id: I45f0aae2bdeea7603f8b7dce206bfdb1c4c38ccc
2016-07-06 16:32:34 +08:00
Sean Dague
c9f5ad3bcf remove /v2.1/{tenant_id} from all urls
As discussed at summit, the version part of the URL is not really
relevant, or a thing a user should be filling out themselves, this
should instead be set by the service catalog and extracted from the
token.

This removes it's reference in all documented REST urls, and adds a
new section describing how one gets the base URL for all calls.

Change-Id: I4306b8c3de0225e54f3909dd8a1fb293c4e5944c
2016-06-03 08:47:33 -04:00
jichenjc
896062a383 Complet Method Verification of os-instance-actions
verified the API doc for os-instance-actions, changes some
wording and the title,
Also, remove some common error code like 500, 503 etc

Part of bp:api-ref-in-rst

Change-Id: Icaf84d86c773ad4173c662dc148219b3aba4a9fc
2016-04-23 22:13:01 +08:00
Sean Dague
d929b9fc76 add tags to files for the content verification phase
This adds a set of tags in comments to the beginning of files so that
we can process them according to the documentation here:
https://wiki.openstack.org/wiki/NovaAPIRef

Part of bp:api-ref-in-rst

Change-Id: I17cf584dafb5bd969c12f51b7e7185d92365bf93
2016-04-20 16:21:58 -04:00
ghanshyam
aa0bb597c6 Fix sample file path for os-i* API
This patch fix sample files path for os-i* APIs

Part of bp:api-ref-in-rst

Change-Id: I0d8de9aaef7ffe5e0dfe09f38246b1f57ac814cb
2016-04-20 11:38:31 +09:00
ghanshyam
6f8cda2f39 Fix json response example heading in api ref
Heading for json response example is wrong,
it is json request instead of json response.

Part of bp:api-ref-in-rst

Change-Id: I709b2bf19520eb76e0264c358a2146bb0dbcee2b
2016-04-19 17:56:20 +09:00
Sean Dague
9526462326 move sphinx h3 to '-' instead of '^'
In the sphinx document h3 is supposed to be '-' not '^':

=, for sections
-, for subsections
^, for subsubsections

We have to enforce consistency here because we're processing included
files which all have to agree, otherwise it's a sphinx error.

Part of bp:api-ref-in-rst

Change-Id: Ic6eef5cacb07870f161b04b031e332f2b87aeedc
2016-04-15 07:43:06 -04:00
Sean Dague
d4e2771440 Import RST files for documentation
This is the results of the RST conversion from WADL. It creates a
single index plus a bunch of included files which represent sections
of the API document. This is the starting point for fixing the
documentation.

Change-Id: I7d561c2ecdcd864172dedb54a551f17ad3bdfe26
2016-04-13 07:34:45 -04:00