Skip to content

Commit fb14f24

Browse files
committed
Remove '/os-cells' REST APIs
Drop support for the os-cells REST APIs, which are part of the cells v1 feature which has been deprecated since Pike. This API now returns a 410 response for all routes. Unit tests are removed and the functional API sample tests are just asserting the 410 response now. The latter are also expanded to cover APIs that weren't previously tested. The API sample docs are left intact since the API reference still builds from those and can be considered more or less branchless, so people looking at the API reference can apply it to older deployments of nova before os-cells was removed. A release note added for previous cells v1 removals is amended to note this additional change. Part of blueprint remove-cells-v1 Change-Id: Iddb519008515f591cf1d884872a5887afbe766f2 Signed-off-by: Stephen Finucane <[email protected]>
1 parent e25d590 commit fb14f24

File tree

20 files changed

+94
-1587
lines changed

20 files changed

+94
-1587
lines changed

api-ref/source/index.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -73,7 +73,6 @@ limited to some maximum microversion.
7373
.. include:: os-security-group-default-rules.inc
7474
.. include:: os-security-group-rules.inc
7575
.. include:: os-hosts.inc
76-
.. include:: os-cells.inc
7776

7877
=============
7978
Obsolete APIs
@@ -89,3 +88,4 @@ Compute API in the past, but no longer exist.
8988
.. include:: os-fixed-ips.inc
9089
.. include:: os-floating-ips-bulk.inc
9190
.. include:: os-floating-ip-dns.inc
91+
.. include:: os-cells.inc

api-ref/source/os-cells.inc

Lines changed: 24 additions & 23 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,4 @@
11
.. -*- rst -*-
2-
.. needs:parameter_verification
3-
.. needs:example_verification
4-
.. needs:body_verification
5-
62
73
==============================
84
Cells (os-cells, capacities)
@@ -11,10 +7,13 @@
117
Adds neighbor cells, lists neighbor cells, and shows the capabilities of
128
the local cell. By default, only administrators can manage cells.
139

14-
.. warning:: These APIs refer to a Cells v1 deployment which was deprecated
15-
in the 16.0.0 Pike release. These are not used with Cells v2
16-
which is required beginning with the 15.0.0 Ocata release where all Nova
17-
deployments consist of at least one Cells v2 cell.
10+
.. warning::
11+
12+
These APIs refer to a Cells v1 deployment which was deprecated in the 16.0.0
13+
Pike release. These are not used with Cells v2 which is required beginning
14+
with the 15.0.0 Ocata release where all Nova deployments consist of at least
15+
one Cells v2 cell.
16+
They were removed in the 20.0.0 Train release.
1817

1918
List Cells
2019
==========
@@ -26,7 +25,7 @@ Lists cells.
2625
Normal response codes: 200
2726

2827
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
29-
NotImplemented(501)
28+
gone(410), notImplemented(501)
3029

3130
Request
3231
-------
@@ -52,10 +51,10 @@ Create Cell
5251

5352
Create a new cell.
5453

55-
Normal response code: 200
54+
Normal response codes: 200
5655

5756
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
58-
NotImplemented(501)
57+
gone(410), notImplemented(501)
5958

6059
Capacities
6160
==========
@@ -64,8 +63,10 @@ Capacities
6463

6564
Retrieve capacities.
6665

66+
Normal response codes: 200
67+
6768
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
68-
NotImplemented(501)
69+
gone(410), notImplemented(501)
6970

7071
List Cells With Details
7172
=======================
@@ -77,7 +78,7 @@ Lists cells with details of capabilities.
7778
Normal response codes: 200
7879

7980
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
80-
NotImplemented(501)
81+
gone(410), notImplemented(501)
8182

8283
Request
8384
-------
@@ -94,10 +95,10 @@ Info For This Cell
9495

9596
Retrieve info about the current cell.
9697

97-
Normal response code: 200
98+
Normal response codes: 200
9899

99100
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
100-
NotImplemented(501)
101+
gone(410), notImplemented(501)
101102

102103
Show Cell Data
103104
==============
@@ -109,7 +110,7 @@ Shows data for a cell.
109110
Normal response codes: 200
110111

111112
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
112-
itemNotFound(404), NotImplemented(501)
113+
itemNotFound(404), gone(410), notImplemented(501)
113114

114115
Request
115116
-------
@@ -129,15 +130,15 @@ Response
129130
Update a Cell
130131
=============
131132

132-
.. rest_method:: PUT /os-cells/{cell_od}
133+
.. rest_method:: PUT /os-cells/{cell_id}
133134

134135

135136
Update an existing cell.
136137

137-
Normal response code: 200
138+
Normal response codes: 200
138139

139140
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
140-
itemNotFound(404), NotImplemented(501)
141+
itemNotFound(404), gone(410), notImplemented(501)
141142

142143
Delete a Cell
143144
=============
@@ -146,10 +147,10 @@ Delete a Cell
146147

147148
Remove a cell.
148149

149-
Normal response code: 200
150+
Normal response codes: 200
150151

151152
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
152-
itemNotFound(404), NotImplemented(501)
153+
itemNotFound(404), gone(410), notImplemented(501)
153154

154155
Show Cell Capacities
155156
====================
@@ -158,10 +159,10 @@ Show Cell Capacities
158159

159160
Shows capacities for a cell.
160161

161-
Normal response codes: 200,501
162+
Normal response codes: 200
162163

163164
Error response codes: badRequest(400), unauthorized(401), forbidden(403),
164-
itemNotFound(404), NotImplemented(501)
165+
itemNotFound(404), gone(410), notImplemented(501)
165166

166167
Request
167168
-------

doc/api_samples/os-cells/cells-list-empty-resp.json

Lines changed: 0 additions & 3 deletions
This file was deleted.

nova/api/openstack/common.py

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,6 @@
1414
# under the License.
1515

1616
import collections
17-
import functools
1817
import itertools
1918
import re
2019

@@ -495,15 +494,6 @@ def get_flavor(context, flavor_id):
495494
raise exc.HTTPNotFound(explanation=error.format_message())
496495

497496

498-
def check_cells_enabled(function):
499-
@functools.wraps(function)
500-
def inner(*args, **kwargs):
501-
if not CONF.cells.enable:
502-
raise_feature_not_supported()
503-
return function(*args, **kwargs)
504-
return inner
505-
506-
507497
def is_all_tenants(search_opts):
508498
"""Checks to see if the all_tenants flag is in search_opts
509499

0 commit comments

Comments
 (0)