Browse Source

Merge "Remove deprecated ip floating commands"

tags/3.16.0
Zuul 1 year ago
parent
commit
a7973d927d

+ 0
- 16
doc/source/cli/command-objects/ip-floating-pool.rst View File

@@ -1,16 +0,0 @@
1
-================
2
-ip floating pool
3
-================
4
-
5
-Compute v2
6
-
7
-ip floating pool list
8
----------------------
9
-
10
-List pools of floating IP addresses
11
-(Deprecated, please use ``floating ip pool list`` instead)
12
-
13
-.. program:: ip floating pool list
14
-.. code:: bash
15
-
16
-    openstack ip floating pool list

+ 0
- 129
doc/source/cli/command-objects/ip-floating.rst View File

@@ -1,129 +0,0 @@
1
-===========
2
-ip floating
3
-===========
4
-
5
-Compute v2, Network v2
6
-
7
-ip floating add
8
----------------
9
-
10
-Add floating IP address to server
11
-(Deprecated, please use ``server add floating ip`` instead)
12
-
13
-.. program:: ip floating add
14
-.. code:: bash
15
-
16
-    openstack ip floating add
17
-        <ip-address>
18
-        <server>
19
-
20
-.. describe:: <ip-address>
21
-
22
-    IP address to add to server (name only)
23
-
24
-.. describe:: <server>
25
-
26
-    Server to receive the IP address (name or ID)
27
-
28
-ip floating create
29
-------------------
30
-
31
-Create new floating IP address
32
-(Deprecated, please use ``floating ip create`` instead)
33
-
34
-.. program:: ip floating create
35
-.. code:: bash
36
-
37
-    openstack ip floating create
38
-        [--subnet <subnet>]
39
-        [--port <port>]
40
-        [--floating-ip-address <floating-ip-address>]
41
-        [--fixed-ip-address <fixed-ip-address>]
42
-        <network>
43
-
44
-.. option:: --subnet <subnet>
45
-
46
-    Subnet on which you want to create the floating IP (name or ID)
47
-    (Network v2 only)
48
-
49
-.. option:: --port <port>
50
-
51
-    Port to be associated with the floating IP (name or ID)
52
-    (Network v2 only)
53
-
54
-.. option:: --floating-ip-address <floating-ip-address>
55
-
56
-    Floating IP address
57
-    (Network v2 only)
58
-
59
-.. option:: --fixed-ip-address <fixed-ip-address>
60
-
61
-    Fixed IP address mapped to the floating IP
62
-    (Network v2 only)
63
-
64
-.. describe:: <network>
65
-
66
-    Network to allocate floating IP from (name or ID)
67
-
68
-ip floating delete
69
-------------------
70
-
71
-Delete floating IP(s)
72
-(Deprecated, please use ``floating ip delete`` instead)
73
-
74
-.. program:: ip floating delete
75
-.. code:: bash
76
-
77
-    openstack ip floating delete
78
-        <floating-ip> [<floating-ip> ...]
79
-
80
-.. describe:: <floating-ip>
81
-
82
-    Floating IP(s) to delete (IP address or ID)
83
-
84
-ip floating list
85
-----------------
86
-
87
-List floating IP addresses
88
-(Deprecated, please use ``floating ip list`` instead)
89
-
90
-.. program:: ip floating list
91
-.. code:: bash
92
-
93
-    openstack ip floating list
94
-
95
-ip floating remove
96
-------------------
97
-
98
-Remove floating IP address from server
99
-(Deprecated, please use ``server remove floating ip`` instead)
100
-
101
-.. program:: ip floating remove
102
-.. code:: bash
103
-
104
-    openstack ip floating remove
105
-        <ip-address>
106
-        <server>
107
-
108
-.. describe:: <ip-address>
109
-
110
-    IP address to remove from server (name only)
111
-
112
-.. describe:: <server>
113
-
114
-    Server to remove the IP address from (name or ID)
115
-
116
-ip floating show
117
-----------------
118
-
119
-Display floating IP details
120
-(Deprecated, please use ``floating ip show`` instead)
121
-
122
-.. program:: ip floating show
123
-.. code:: bash
124
-
125
-    openstack ip floating show <floating-ip>
126
-
127
-.. describe:: <floating-ip>
128
-
129
-    Floating IP to display (IP address or ID)

+ 0
- 98
openstackclient/network/v2/floating_ip.py View File

@@ -13,8 +13,6 @@
13 13
 
14 14
 """IP Floating action implementations"""
15 15
 
16
-import logging
17
-
18 16
 from osc_lib.command import command
19 17
 from osc_lib import utils
20 18
 
@@ -159,30 +157,6 @@ class CreateFloatingIP(common.NetworkAndComputeShowOne):
159 157
         return (columns, data)
160 158
 
161 159
 
162
-class CreateIPFloating(CreateFloatingIP):
163
-    _description = _("Create floating IP")
164
-
165
-    # TODO(tangchen): Remove this class and ``ip floating create`` command
166
-    #                 two cycles after Mitaka.
167
-
168
-    # This notifies cliff to not display the help for this command
169
-    deprecated = True
170
-
171
-    log = logging.getLogger('deprecated')
172
-
173
-    def take_action_network(self, client, parsed_args):
174
-        self.log.warning(_('This command has been deprecated. '
175
-                           'Please use "floating ip create" instead.'))
176
-        return super(CreateIPFloating, self).take_action_network(
177
-            client, parsed_args)
178
-
179
-    def take_action_compute(self, client, parsed_args):
180
-        self.log.warning(_('This command has been deprecated. '
181
-                           'Please use "floating ip create" instead.'))
182
-        return super(CreateIPFloating, self).take_action_compute(
183
-            client, parsed_args)
184
-
185
-
186 160
 class DeleteFloatingIP(common.NetworkAndComputeDelete):
187 161
     _description = _("Delete floating IP(s)")
188 162
 
@@ -210,30 +184,6 @@ class DeleteFloatingIP(common.NetworkAndComputeDelete):
210 184
         client.api.floating_ip_delete(self.r)
211 185
 
212 186
 
213
-class DeleteIPFloating(DeleteFloatingIP):
214
-    _description = _("Delete floating IP(s)")
215
-
216
-    # TODO(tangchen): Remove this class and ``ip floating delete`` command
217
-    #                 two cycles after Mitaka.
218
-
219
-    # This notifies cliff to not display the help for this command
220
-    deprecated = True
221
-
222
-    log = logging.getLogger('deprecated')
223
-
224
-    def take_action_network(self, client, parsed_args):
225
-        self.log.warning(_('This command has been deprecated. '
226
-                           'Please use "floating ip delete" instead.'))
227
-        return super(DeleteIPFloating, self).take_action_network(
228
-            client, parsed_args)
229
-
230
-    def take_action_compute(self, client, parsed_args):
231
-        self.log.warning(_('This command has been deprecated. '
232
-                           'Please use "floating ip delete" instead.'))
233
-        return super(DeleteIPFloating, self).take_action_compute(
234
-            client, parsed_args)
235
-
236
-
237 187
 class ListFloatingIP(common.NetworkAndComputeLister):
238 188
     # TODO(songminglong): Use SDK resource mapped attribute names once
239 189
     # the OSC minimum requirements include SDK 1.0
@@ -384,30 +334,6 @@ class ListFloatingIP(common.NetworkAndComputeLister):
384 334
                 ) for s in data))
385 335
 
386 336
 
387
-class ListIPFloating(ListFloatingIP):
388
-    _description = _("List floating IP(s)")
389
-
390
-    # TODO(tangchen): Remove this class and ``ip floating list`` command
391
-    #                 two cycles after Mitaka.
392
-
393
-    # This notifies cliff to not display the help for this command
394
-    deprecated = True
395
-
396
-    log = logging.getLogger('deprecated')
397
-
398
-    def take_action_network(self, client, parsed_args):
399
-        self.log.warning(_('This command has been deprecated. '
400
-                           'Please use "floating ip list" instead.'))
401
-        return super(ListIPFloating, self).take_action_network(
402
-            client, parsed_args)
403
-
404
-    def take_action_compute(self, client, parsed_args):
405
-        self.log.warning(_('This command has been deprecated. '
406
-                           'Please use "floating ip list" instead.'))
407
-        return super(ListIPFloating, self).take_action_compute(
408
-            client, parsed_args)
409
-
410
-
411 337
 class SetFloatingIP(command.Command):
412 338
     _description = _("Set floating IP Properties")
413 339
 
@@ -499,30 +425,6 @@ class ShowFloatingIP(common.NetworkAndComputeShowOne):
499 425
         return (columns, data)
500 426
 
501 427
 
502
-class ShowIPFloating(ShowFloatingIP):
503
-    _description = _("Display floating IP details")
504
-
505
-    # TODO(tangchen): Remove this class and ``ip floating show`` command
506
-    #                 two cycles after Mitaka.
507
-
508
-    # This notifies cliff to not display the help for this command
509
-    deprecated = True
510
-
511
-    log = logging.getLogger('deprecated')
512
-
513
-    def take_action_network(self, client, parsed_args):
514
-        self.log.warning(_('This command has been deprecated. '
515
-                           'Please use "floating ip show" instead.'))
516
-        return super(ShowIPFloating, self).take_action_network(
517
-            client, parsed_args)
518
-
519
-    def take_action_compute(self, client, parsed_args):
520
-        self.log.warning(_('This command has been deprecated. '
521
-                           'Please use "floating ip show" instead.'))
522
-        return super(ShowIPFloating, self).take_action_compute(
523
-            client, parsed_args)
524
-
525
-
526 428
 class UnsetFloatingIP(command.Command):
527 429
     _description = _("Unset floating IP Properties")
528 430
 

+ 0
- 25
openstackclient/network/v2/floating_ip_pool.py View File

@@ -13,7 +13,6 @@
13 13
 
14 14
 """Floating IP Pool action implementations"""
15 15
 
16
-import logging
17 16
 
18 17
 from osc_lib import exceptions
19 18
 from osc_lib import utils
@@ -40,27 +39,3 @@ class ListFloatingIPPool(common.NetworkAndComputeLister):
40 39
                 (utils.get_dict_properties(
41 40
                     s, columns,
42 41
                 ) for s in data))
43
-
44
-
45
-class ListIPFloatingPool(ListFloatingIPPool):
46
-    _description = _("List pools of floating IP addresses")
47
-
48
-    # TODO(tangchen): Remove this class and ``ip floating pool list`` command
49
-    #                 two cycles after Mitaka.
50
-
51
-    # This notifies cliff to not display the help for this command
52
-    deprecated = True
53
-
54
-    log = logging.getLogger('deprecated')
55
-
56
-    def take_action_network(self, client, parsed_args):
57
-        self.log.warning(_('This command has been deprecated. '
58
-                           'Please use "floating ip pool list" instead.'))
59
-        return super(ListIPFloatingPool, self).take_action_network(
60
-            client, parsed_args)
61
-
62
-    def take_action_compute(self, client, parsed_args):
63
-        self.log.warning(_('This command has been deprecated. '
64
-                           'Please use "floating ip pool list" instead.'))
65
-        return super(ListIPFloatingPool, self).take_action_compute(
66
-            client, parsed_args)

+ 4
- 0
releasenotes/notes/remove-ip-floating-commands-d5363f313e09249a.yaml View File

@@ -0,0 +1,4 @@
1
+---
2
+other:
3
+  - |
4
+    Remove deprecated ``ip floating`` and ``ip floating pool`` commands.

+ 0
- 7
setup.cfg View File

@@ -379,13 +379,6 @@ openstack.network.v2 =
379 379
     ip_availability_list = openstackclient.network.v2.ip_availability:ListIPAvailability
380 380
     ip_availability_show = openstackclient.network.v2.ip_availability:ShowIPAvailability
381 381
 
382
-    ip_floating_create = openstackclient.network.v2.floating_ip:CreateIPFloating
383
-    ip_floating_delete = openstackclient.network.v2.floating_ip:DeleteIPFloating
384
-    ip_floating_list = openstackclient.network.v2.floating_ip:ListIPFloating
385
-    ip_floating_show = openstackclient.network.v2.floating_ip:ShowIPFloating
386
-
387
-    ip_floating_pool_list = openstackclient.network.v2.floating_ip_pool:ListIPFloatingPool
388
-
389 382
     network_agent_add_network = openstackclient.network.v2.network_agent:AddNetworkToAgent
390 383
     network_agent_add_router = openstackclient.network.v2.network_agent:AddRouterToAgent
391 384
     network_agent_delete = openstackclient.network.v2.network_agent:DeleteNetworkAgent

Loading…
Cancel
Save