792 Commits

Author SHA1 Message Date
Jenkins
3d4f257aa9 Merge "Remove 40X and 50X from Normal response codes" 2016-04-19 15:02:15 +00:00
Jenkins
d3b4bcb78a Merge "Specify normal status code on os-baremetal-nodes" 2016-04-19 14:44:58 +00:00
Jenkins
bb64ef88fd Merge "Fix "Creates an aggregate" parameters" 2016-04-19 13:24:40 +00:00
Kevin_Zheng
b9a89c97a8 Fix api ref for os-hosts, os-quota-sets and os-fping
This patch fix API ref for correct sample files and status code
for below APIs
- os-hosts
- os-quota-sets
- os-fping

Part of bp:api-ref-in-rst

Change-Id: I7ecfe5adf4d8f1e9c767bac9194d9160f09fbee9
2016-04-19 21:18:12 +08:00
Kevin_Zheng
f774d03b6f Fix api ref for os-cells, os-cloudpipe and server-action-shelve
This patch fix API ref for correct sample files and status code
for below APIs
- os-cells
- os-cloudpipe
- server-action-shelve

Part of bp:api-ref-in-rst

Change-Id: I6292f78742d7bb50882e186c97e7966721037ba4
2016-04-19 13:08:49 +00:00
Kevin_Zheng
f6592c94fd Fix api sample references in 2 more files.
The api sample reference is not correct
fix incorrect return value.

1. servers-action-console-output.inc
2. servers-action-crash-dump.inc

Part of bp:api-ref-in-rst

Change-Id: Id0d946478a6a59f63f22117944309d3eb66013d3
2016-04-19 20:32:58 +08:00
ghanshyam
d8f9d2328e Fix api ref for ips, limits, metdata and agent
This patch fix API ref for correct sample files and status code
for below APIs
- ips
- limits
- server metadata
- agents

Part of bp:api-ref-in-rst

Change-Id: I91b769eefde78381dc0feb6b5c8c6cf753203732
2016-04-19 19:32:48 +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
Jenkins
654181beeb Merge "Fix hosts and az api samples" 2016-04-19 08:02:43 +00:00
Jenkins
3f0865b22a Merge "Fix "Creates an agent build" parameters" 2016-04-19 06:33:35 +00:00
Jenkins
2848ef3bff Merge "Fix os-service related reference missing" 2016-04-19 02:37:00 +00:00
Ken'ichi Ohmichi
05e9f0a0e0 Remove 40X and 50X from Normal response codes
HTTP 40X-50X are not normal response codes at all.
This patch removes them from api-ref.

Part of bp:api-ref-in-rst

Change-Id: I32a29c9e2a3d69720e3a88e17ba36fe45fa902d9
2016-04-18 16:56:11 -07:00
Ken'ichi Ohmichi
cf2fb50006 Specify normal status code on os-baremetal-nodes
The api-ref os-baremetal-nodes doesn't contain normal status code,
so this patch adds it for explaining the normal opperation.

Part of bp:api-ref-in-rst

Change-Id: I1e1e9ee37b1a8c0511438fa9a2e447c7d8df8d0f
2016-04-18 16:55:57 -07:00
Ken'ichi Ohmichi
b3e1afd087 Fix "Creates an aggregate" parameters
"Creates an aggregate" API supports multiple parameters on a request,
but api-ref doesn.t contain them at all This patch adds them.

The following JSON-Schema is for the API.
https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/schemas/aggregates.py#L32

Part of bp:api-ref-in-rst

Change-Id: I3a58568662d21059bccdcf64cc30dbf3b706db58
2016-04-18 14:25:24 -07:00
Sean Dague
afe8c1b3e8 fix samples references for 2 files
This fixes the samples references for ``servers-actions.inc`` and
``servers-multiple-create.inc`` and drops the warnings count to 195.

Change-Id: Id9a2ae98f5ded9ab57bfd3af5fb18357df6bc1d2
2016-04-18 07:15:10 -04:00
Sean Dague
46a1fd17cc Update servers.inc to be as accurate as api-site
This updates servers.inc which had a rough path during conversion. The
GET servers/details was lost entirely.

It updates a number of parameters to distinguish ones that are only in
the queries, as well as fixes references to short names that collided.

It updates the UPDATE call to only specify request parameters which
you can actually update.

It introduces the notation object.field for parameters that are
embedded in other objects. This is a new concept, but one way we can
clear up that the uuid in the parameter list is really networks.uuid.

It also deletes the old hand rolled servers.rst, which drops the
warnings count by nearly 100.

Part of bp:api-ref-in-rst

Change-Id: Ie7693a5888efa913118244a0837e6c0177965d48
2016-04-18 06:40:23 -04:00
Ken'ichi Ohmichi
93e3784a6e Fix "Creates an agent build" parameters
"Creates an agent build" API supports multiple parameters on a request,
but api-ref doesn.t contain them at all This patch adds them.

The following JSON-Schema is for the API.
https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/schemas/agents.py#L21

Part of bp:api-ref-in-rst

Change-Id: I4b026f691711b11c1918785dff89bf5196c7177d
2016-04-15 14:33:53 -07:00
Sean Dague
138a3eae7d clean up versions.inc reference document
This fixes a number of issues in the versions.inc reference
document.

Documents all the useful parameters in the response (we really need to
do something about the ones that are not).

Fix links to samples content, and write some text explaining them.

Parametrize the {api_version} GET call, it was weird to list all the
hard coded values there.

Add a couple of inline todos for longer additional references we
should do.

Part of bp:api-ref-in-rst

Change-Id: I56e5e922fca39453d0d9fc062a84daba7cad8cc1
2016-04-15 11:44:00 -07:00
Sean Dague
40630d731b Collection of CSS fixes
This ensures all parameter tables are 100% wide, even if they have
only a few items with short descriptions. It makes all the tables the
same width.

This moves the link icon into the gutter for the main content, and
makes it hidden by default (only visible on hover) like in the API
site today.

This makes the link + method name div be ``white-space: nowrap`` to
ensure that when the screen gets narrower the Delete button doesn't
fold up on itself.

Part of bp:api-ref-in-rst

Change-Id: I3892e6c8e3c01956d63a33603ba1bf9146d21161
2016-04-15 12:18:44 -04: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
ccee8b3c13 fix blockquote font size
The blockquote font size is 17.5px in bootstrap where normal text is
14px. This is because blockquote is thought of for doing pull
quotes. However sphinx uses block quote for indented text, and it
should thus be the same as the body text.

Part of bp:api-ref-in-rst

Change-Id: I4135686416d84f5ca113a031534c3486a4c2b1c5
2016-04-15 07:43:06 -04:00
Sean Dague
e51b8f43e1 Add 'Show All' / 'Hide All' toggle
This adds a global control that does show / hide of all collapseable
sections. Which is extremely useful in seeing the entire API at once.

Part of bp:api-ref-in-rst

Change-Id: I814e6b2c20c25bf3d4cb4e722bc8157ca0aa1b89
2016-04-15 07:43:06 -04:00
Sean Dague
19712dccce use 'required' instead of 'optional' for parameters
In swagger the attribute for required/optional is 'required', so we've
decided that's a better way to specify our parameters. This changes
the sphinx parser to use that when inserting (optional) into the
table.

We also make all 'path' parameters required, because we never specify
them in a table where they are not. I think them all being required:
false was an artifact of the data processing.

Part of bp:api-ref-in-rst

Change-Id: Ie2d012741d69430546fe1b10c9f16c853acb926a
2016-04-15 07:43:06 -04:00
Sean Dague
5bc00aac40 Fix css references to the glyphicons font
The bootstrap css uses the glyphicons font, but sphinx can't put it
exactly in the same place that bootstrap wants it. So fix the
minimized css to make it available and include those fonts in our
tree.

Part of bp:api-ref-in-rst

Change-Id: Ib45b90966ce12194fcb571c2782b1baed7af2471
2016-04-15 07:43:06 -04:00
Karen Bradshaw
aa9a270159 Fix formatting of rst in parameters.yaml
Change-Id: Ia30d1922a756f4bfefd997ab34c799e1919f2540
2016-04-14 14:35:08 -04:00
Sean Dague
9e305c2508 cleanup some issues in parameters.yaml
Change-Id: I47334dab81790573f5f656682e3113bed44d2cc4
2016-04-13 07:55:53 -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
Sean Dague
f1fa7eb15a add combined parameters.yaml file
This is the output of fairy-slipper conversion, merged into a single
file, with some error collision put into place. This will require some
unwinding of content because of the collisions that exist in keys, but
that can be done manually post import.

Change-Id: I430ed66728a6ac009f23e6ff8a65a3ec01c21327
2016-04-13 07:34:09 -04:00
Thomas Bechtold
82a23c682e Fix doc build if git is absent
When building packages if git is absent, then we should not set
html_last_updated_fmt. It can still be set via the -D switch
when building with sphinx-build.

Change-Id: I5da86b7a163c0e795cd34abf79b0980a8552f79b
Closes-Bug: #1552251
2016-04-13 09:35:57 +02:00
Sean Dague
329898ffbc Add sample API content
This adds sample API content for versions and servers resources,
including the parameters.yaml that is needed in both of these cases.

It also makes a new tox.ini target 'api-ref' for building these docs,
which will be used as part of the publishing pipeline.

Change-Id: I310ed352dc5dd81d01f2fd5f1a2fab662c29f0dc
2016-03-29 16:35:33 -04:00
Sean Dague
68ec070645 Create api-ref docs site
This creates a stub for landing content to support having the source
for the api-ref site in our source tree. It includes a new sphinx
extension that will be used to generate the html needed for the site
which supports 2 new stanzas:

 .. rest_parameters::

This uses a parameters yaml file to look up the definitions of
parameters and produce a structured table of those parameters and how
they are used.

 .. rest_method::

This is a stanza used inside a section which specifies the REST method
(i.e. GET /servers/{id}) which is then used to produce a nice
collapsable section.

This uses quite a bit of the sphinx extension API, and tries to
document any non obvious actions.

This extension needs additional styling from bootstrap, and some
custom js / css to do the theming / collapsing. That's included as
part of this.

Change-Id: I41b568b782d3c85f6ef8d3bb3a6f4ae378e4dc33
2016-03-29 16:35:33 -04:00
jichenjc
11a79609e3 modify duplicate // to / in doc
Part of bp:api-ref-in-rst

Change-Id: I1da87f0e8f0a6b45d60be58af2d13c8a236469d3
2016-03-24 05:01:06 +08:00
jichenjc
dfcd3a3c91 change host to host_migration
host param in migration refer to wrong link.

Part of bp:api-ref-in-rst

Change-Id: I7bf2459dace2cf0a90ae32f75ed734f533219c63
2016-03-24 04:39:50 +08:00
jichenjc
f03a3a5be4 Update 'os-hypervisors.inc' in api-ref
some changes including:
1) update the wrong reference link to json file
2) Add /v2.1/{tenant_id}/os-hypervisors/detail
3) Add /v2.1/{tenant_id}/os-hypervisors/{hypervisor_id}/search
4) Add /v2.1/{tenant_id}/os-hypervisors/{hypervisor_id}/servers

Part of bp:api-ref-in-rst

Change-Id: I73fbf4583cd75afb2f60c57acd1bdb179f86a9e9
2016-03-24 02:42:03 +08:00
jichenjc
356aa087bb Fix os-server-groups.inc
some json reponse/request reference not correct
fix incorrect return value.
Also, change id reference to server_group_id.

Part of bp:api-ref-in-rst

Change-Id: Ia1fc10301dfa35087658d311bec684d43c8e0929
2016-03-24 02:30:28 +08:00
jichenjc
a248e6c60b Change adminPass for several server actions
adminPass has incorrect reference, thus every input param
are same ,but actually they are different. updated it with its
correct link reference.

Part of bp:api-ref-in-rst

Change-Id: Ie981a0912768effbe796bfc1d26d4972ba667b90
2016-03-23 22:49:44 +08:00
jichenjc
6bc51e4d2e Fix os-virtual-interfaces and flavors api-ref
fix api-sample reference to flavors
make some changes to os-virtual-interfaces so don't talk
about microversion in contents(will add microversion later)
also, fix id param reference

Part of bp:api-ref-in-rst

Change-Id: I6eb8a14fce1c1048506cd5b990576ca5ecf44b6c
2016-03-23 22:03:57 +08:00
jichenjc
a26f6b43e5 Fix flavor-access and flavor-extras api-ref
flavor-access and flavor-extras api-ref has wrong reference
this patch fixed it.

Part of bp:api-ref-in-rst

Change-Id: I07fed203b2f3908bade0e087265384349e21830c
2016-03-23 20:01:42 +08:00
jichenjc
17c09561f4 Fix diagnostics, extensions api ref
update those files api-ref

Part of bp:api-ref-in-rst

Change-Id: Id68dbc77011a7414edda5a4855ccbddb204031ac
2016-03-23 19:17:40 +08:00
jichenjc
fb7b7e7f95 Fix hosts and az api samples
Those 2 files has incorrect api samples, this patch fixs it.

Part of bp:api-ref-in-rst

Change-Id: I71033531fefdb27b191a3a5abb3cba6fbb48b6c1
2016-03-23 13:58:30 +08:00
jichenjc
e9cb0aa036 Fix os-service related reference missing
"Delete a service " API returns 204 as success, 404 is error
Also some reference to doc it not correct

Part of bp:api-ref-in-rst

Change-Id: Ibf57167ae70acdaa2ad6f0abc3a975c91e797b87
2016-03-23 10:25:11 +08:00
jichenjc
d761ba3bd4 Add 'binary' and 'disable-reason' into os-service
there are references in os-service.inc to binary and disable-reason
but the definitions are missing in parameters.yaml

definitions are here:
https://github.com/openstack/nova/blob/master/nova/api/openstack/compute/schemas/services.py

Part of bp:api-ref-in-rst

Change-Id: Ic371c68cc57c43dc8e866482e901a1d0e7aa18c7
2016-03-23 09:39:43 +08:00