diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/bgp_dragent_scheduler.inc python-neutron-lib-3.4.0/api-ref/source/v2/bgp_dragent_scheduler.inc --- python-neutron-lib-3.3.0/api-ref/source/v2/bgp_dragent_scheduler.inc 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/bgp_dragent_scheduler.inc 2023-02-10 16:29:50.000000000 +0000 @@ -0,0 +1,97 @@ +.. -*- rst -*- + +================================================= +BGP Speaker and Dynamic Routing Agent interaction +================================================= + +Add BGP Speaker to a Dynamic Routing Agent +========================================== + +.. rest_method:: POST /v2.0/agents/{bgp-agent-id}/bgp-drinstances + +Issue a ``POST`` request to ``/v2.0/agents/{bgp-agent-id}/bgp-drinstances`` to +add a BGP Speaker to the specified dynamic routing agent. + +Normal response codes: 201 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - bgp_speaker_id: bgp_speaker-id-body + +Request Example +--------------- + +.. literalinclude:: samples/bgp/dragent_add_speaker-request.json + :language: javascript + +Response +-------- + +There is no body content for the response of a successful add +BGP Speaker to a Dynamic Routing Agent. + +List BGP speakers hosted by a Dynamic Routing Agent +=================================================== + +.. rest_method:: GET /v2.0/agents/{bgp-dragent-id}/bgp-drinstances + +Issue a ``GET`` request to ``/v2.0/agents/{bgp-dragent-id}/bgp-drinstances`` to +list all BGP Seakers hosted on the specified dynamic routing agent. + +Normal response codes: 200 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - bgp-dragent-id: bgp_dragent_id-path + +Response Parameters +------------------- + +.. rest_parameters:: parameters.yaml + + - bgp_speakers: bgp_speakers + - id: bgp_speaker-id-body + - peers: bgp_peers + - name: bgp_speaker-name-body + - ip_version: bgp_speaker_ip_version-body + - advertise_floating_ip_host_routes: bgp_speaker_advertise_fip_host_routes-body + - advertise_tenant_networks: bgp_speaker_advertise_tenant_net-body + - local_as: bgp_speaker_local_as_body + - networks: bgp_speaker-networks-body + - project_id: project_id + +Response Example +---------------- + +.. literalinclude:: samples/bgp/dragent_list_speakers-response.json + :language: javascript + +Delete BGP Speaker from a Dynamic Routing Agent +=============================================== + +.. rest_method:: DELETE /v2.0/agents/{bgp-agent-id}/bgp-drinstances/{bgp-speaker-id} + +Issue a ``DELETE`` request to ``/v2.0/agents/{bgp-agent-id}/bgp-drinstances/{bgp-speaker-id}`` +to delete the BGP Speaker hosted by the specified dynamic routing agent. + +Normal response codes: 204 + +Request +------- + +.. rest_parameters:: parameters.yaml + + - bgp-speaker-id: bgp_speaker_id-path + - bgp-dragent-id: bgp_dragent_id-path + +Response +-------- + +There is no body content for the response of a successful DELETE request. + diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/bgp_speaker.inc python-neutron-lib-3.4.0/api-ref/source/v2/bgp_speaker.inc --- python-neutron-lib-3.3.0/api-ref/source/v2/bgp_speaker.inc 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/bgp_speaker.inc 2023-02-10 16:29:50.000000000 +0000 @@ -207,7 +207,7 @@ Add BGP Peer to a BGP Speaker ============================= -.. rest_method:: PUT /v2.0/bgp-speakers//add-bgp-peer +.. rest_method:: PUT /v2.0/bgp-speakers/{bgp-speaker-id}/add_bgp_peer Bind the BGP peer to the specified BGP Speaker. @@ -243,7 +243,7 @@ Remove BGP Peer from a BGP Speaker ================================== -.. rest_method:: PUT /v2.0/bgp-speakers//remove-bgp-peer +.. rest_method:: PUT /v2.0/bgp-speakers/{bgp-speaker-id}/remove_bgp_peer Unbind the BGP peer from a BGP Speaker. @@ -271,7 +271,7 @@ Add Network to a BGP Speaker ============================ -.. rest_method:: PUT /v2.0/bgp-speakers//add_gateway_network +.. rest_method:: PUT /v2.0/bgp-speakers/{bgp-speaker-id}/add_gateway_network Add a network to the specified BGP speaker. @@ -308,16 +308,35 @@ Delete Network from a BGP Speaker ================================= -.. rest_method:: PUT /v2.0/bgp-speakers//remove_gateway_network +.. rest_method:: PUT /v2.0/bgp-speakers/{bgp-speaker-id}/remove_gateway_network Remove a network from the specified BGP speaker. Normal response codes: 200 +Request +------- + +.. rest_parameters:: parameters.yaml + + - bgp-speaker-id: bgp_speaker_id-path + - network_id: network_id + +Request Example +--------------- + +.. literalinclude:: samples/bgp/bgp_speaker_remove_network-request.json + :language: javascript + +Response +-------- + +There is no body content for the response of a successful DELETE request. + List routes advertised by a BGP Speaker ======================================= -.. rest_method:: GET /v2.0/bgp-speakers//get_advertised_routes +.. rest_method:: GET /v2.0/bgp-speakers/{bgp-speaker-id}/get_advertised_routes List all routes advertised by the specified BGP Speaker. @@ -341,7 +360,7 @@ List Dynamic Routing Agents hosting a specific BGP Speaker ========================================================== -.. rest_method:: GET /v2.0/bgp-speakers//bgp-dragents +.. rest_method:: GET /v2.0/bgp-speakers/{bgp-speaker-id}/bgp-dragents List all BGP dynamic agents which are hosting the specified BGP Speaker. diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/floatingips.inc python-neutron-lib-3.4.0/api-ref/source/v2/floatingips.inc --- python-neutron-lib-3.3.0/api-ref/source/v2/floatingips.inc 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/floatingips.inc 2023-02-10 16:29:50.000000000 +0000 @@ -10,6 +10,13 @@ The data in these attributes will be published in an external DNS service when Neutron is configured to integrate with such a service. +Floating IP distributed +======================== + +The ``floating-ip-distributed`` extension adds the ``distributed`` attribute +to the floating IPs. The value of this attribute identify the Floating IP is +distributed or centralized. + Floating IP port details ======================== @@ -97,6 +104,7 @@ - project_id: project_id-query - revision_number: revision_number-query - description: description-query + - distributed: fip-distributed-request - floating_network_id: floating_network_id-query - fixed_ip_address: floatingip-fixed_ip_address-query - floating_ip_address: floating_ip_address-query @@ -124,6 +132,7 @@ - updated_at: updated_at_resource - revision_number: revision_number - description: description + - distributed: fip-distributed - dns_domain: dns_domain - dns_name: dns_name - port_details: floating_port_details @@ -216,6 +225,7 @@ - floating_ip_address: floating_ip_address-request - port_id: floatingip-port_id-post-request - subnet_id: floatingip-subnet_id + - distributed: fip-distributed-request - description: description-request - dns_domain: dns_domain-request - dns_name: dns_name-request @@ -236,6 +246,7 @@ - router_id: floatingip-router_id - status: floatingip-status - description: description + - distributed: fip-distributed - dns_domain: dns_domain - dns_name: dns_name - port_details: floating_port_details @@ -304,6 +315,7 @@ - router_id: floatingip-router_id - status: floatingip-status - description: description + - distributed: fip-distributed - dns_domain: dns_domain - dns_name: dns_name - port_details: floating_port_details @@ -364,6 +376,7 @@ - port_id: floatingip-port_id-put-request - fixed_ip_address: floatingip-fixed_ip_address-request - description: description-request + - distributed: fip-distributed-request Request Example --------------- @@ -396,6 +409,7 @@ - updated_at: updated_at_resource - revision_number: revision_number - description: description + - distributed: fip-distributed - dns_domain: dns_domain - dns_name: dns_name - port_details: floating_port_details diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/index.rst python-neutron-lib-3.4.0/api-ref/source/v2/index.rst --- python-neutron-lib-3.3.0/api-ref/source/v2/index.rst 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/index.rst 2023-02-10 16:29:50.000000000 +0000 @@ -98,6 +98,7 @@ ################### .. include:: bgp_speaker.inc .. include:: bgp_peer.inc +.. include:: bgp_dragent_scheduler.inc ####### Logging ####### diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/parameters.yaml python-neutron-lib-3.4.0/api-ref/source/v2/parameters.yaml --- python-neutron-lib-3.3.0/api-ref/source/v2/parameters.yaml 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/parameters.yaml 2023-02-10 16:29:50.000000000 +0000 @@ -19,6 +19,12 @@ in: path required: true type: string +bgp_dragent_id-path: + description: | + The ID of the dynamic routing agent. + in: path + required: true + type: string bgp_speaker_id-path: description: | The ID of the BGP Speaker. @@ -2767,8 +2773,7 @@ description: | A port device profile is a reference for Cyborg project and is a named set of the user requirements for one or more acceletators. - https://docs.openstack.org/api-ref/accelerator/v2/index.html# - device-profiles + https://docs.openstack.org/api-ref/accelerator/#device-profiles in: body required: False type: string @@ -2776,8 +2781,7 @@ description: | A port device profile is a reference for Cyborg project and is a named set of the user requirements for one or more acceletators. - https://docs.openstack.org/api-ref/accelerator/v2/index.html# - device-profiles + https://docs.openstack.org/api-ref/accelerator/#device-profiles in: body required: False type: string @@ -3074,6 +3078,20 @@ in: body required: false type: array +fip-distributed: + description: | + ``true`` indicates a distributed floatingip. + It is available when ``floating-ip-distributed`` extension is enabled. + in: body + required: true + type: boolean +fip-distributed-request: + description: | + ``true`` indicates a distributed floatingip. + It is available when ``floating-ip-distributed`` extension is enabled. + in: body + required: false + type: boolean fip_port_forwarding: description: | A ``floating IP port forwarding`` object. diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/ports.inc python-neutron-lib-3.4.0/api-ref/source/v2/ports.inc --- python-neutron-lib-3.3.0/api-ref/source/v2/ports.inc 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/ports.inc 2023-02-10 16:29:50.000000000 +0000 @@ -61,7 +61,7 @@ of user requirements for one or more acceletators. This parameter is a reference for Cyborg project, read by Nova when a port is requested. If this parameter is populated, Nova makes a request to Cyborg. -https://docs.openstack.org/api-ref/accelerator/v2/index.html#device-profiles +https://docs.openstack.org/api-ref/accelerator/#device-profiles Extra DHCP option (``extra_dhcp_opt``) extension ================================================ @@ -110,6 +110,18 @@ ``binding:`` including ``binding:host_id``, ``binding:vnic_type``, ``binding:vif_type``, ``binding:vif_details``, and ``binding:profile``. +Port hints +========== + +The port hints extension (``port-hints``) introduces the ``hints`` +port attribute. Hints are backend specific pieces of information, +mainly to allow backend specific performance tuning. In itself this +extension defines no particular hint, and therefore no valid values of +the ``hints`` attribute. It just serves as the base for other extensions +introducing concrete hints and signals the presence of the ``hints`` +port attribute to the API user. By default policy, use of the ``hints`` +attribute is restricted to admininstrative users. + Port resource request ===================== diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/bgp_speaker_remove_network-request.json python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/bgp_speaker_remove_network-request.json --- python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/bgp_speaker_remove_network-request.json 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/bgp_speaker_remove_network-request.json 2023-02-10 16:29:50.000000000 +0000 @@ -0,0 +1,3 @@ +{ + "network_id":"f2269b61-6755-4174-8f64-5e318617b204" +} \ No newline at end of file diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_add_speaker-request.json python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_add_speaker-request.json --- python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_add_speaker-request.json 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_add_speaker-request.json 2023-02-10 16:29:50.000000000 +0000 @@ -0,0 +1,3 @@ +{ + "bgp_speaker_id": "5639072c-49eb-480a-9f11-953386589bc8" +} \ No newline at end of file diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_list_agents_hosting_speaker-response.json python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_list_agents_hosting_speaker-response.json --- python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_list_agents_hosting_speaker-response.json 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_list_agents_hosting_speaker-response.json 2023-02-10 16:29:50.000000000 +0000 @@ -0,0 +1,25 @@ +{ + "agents":[ + { + "binary":"neutron-bgp-dragent", + "description":null, + "admin_state_up":true, + "heartbeat_timestamp":"2016-05-17 03:05:12", + "availability_zone":null, + "alive":true, + "topic":"bgp_dragent", + "host":"yangyubj-virtual-machine", + "agent_type":"BGP dynamic routing agent", + "resource_versions":{ + }, + "created_at":"2016-05-09 07:38:00", + "started_at":"2016-05-11 09:06:13", + "id":"af216618-29d3-4ee7-acab-725bdc90e614", + "configurations":{ + "advertise_routes":0, + "bgp_peers":0, + "bgp_speakers":1 + } + } + ] +} \ No newline at end of file diff -Nru python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_list_speakers-response.json python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_list_speakers-response.json --- python-neutron-lib-3.3.0/api-ref/source/v2/samples/bgp/dragent_list_speakers-response.json 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/api-ref/source/v2/samples/bgp/dragent_list_speakers-response.json 2023-02-10 16:29:50.000000000 +0000 @@ -0,0 +1,17 @@ +{ + "bgp_speakers":[ + { + "peers":[ + ], + "name":"bgp-speaker", + "tenant_id":"34a6e17a48cf414ebc890367bf42266b", + "local_as":1000, + "advertise_tenant_networks":true, + "networks":[ + ], + "ip_version":4, + "advertise_floating_ip_host_routes":true, + "id":"b759b2a1-27f4-4a6b-bb61-f2c9a22c9902" + } + ] +} \ No newline at end of file diff -Nru python-neutron-lib-3.3.0/AUTHORS python-neutron-lib-3.4.0/AUTHORS --- python-neutron-lib-3.3.0/AUTHORS 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/AUTHORS 2023-02-10 16:30:14.000000000 +0000 @@ -95,6 +95,7 @@ Matt Riedemann Matt Welch Matthias Lisin +Maurice Escher Michael Johnson Michal Kelner Mishali Miguel Lavalle @@ -150,6 +151,7 @@ Thomas Goirand Thomas Morin Thomas Morin +Tobias Urdin Tony Breeds Tony Xu Trevor McCasland diff -Nru python-neutron-lib-3.3.0/ChangeLog python-neutron-lib-3.4.0/ChangeLog --- python-neutron-lib-3.3.0/ChangeLog 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/ChangeLog 2023-02-10 16:30:14.000000000 +0000 @@ -1,6 +1,22 @@ CHANGES ======= +3.4.0 +----- + +* Use new get\_rpc\_client API from oslo.messaging +* port-hints: api definition +* Fix pep8 errors with pytlint v2.16.0 +* [sqlalchemy-20] Use \`\`Session.get\_transaction()\`\` +* api-ref: Add dragent scheduler api-ref +* [sqlalchemy-20] Fix import of "ASSOCIATION\_PROXY" +* Update envlist for tox4 +* api-ref: fix nits in BGP-Speaker api-ref +* add DEVICE\_OWNER\_MANILA\_PREFIX to constants +* [ovn]Floating IP adds distributed attributes +* Fix a few broken links in api-ref +* Support tox4 + 3.3.0 ----- diff -Nru python-neutron-lib-3.3.0/debian/changelog python-neutron-lib-3.4.0/debian/changelog --- python-neutron-lib-3.3.0/debian/changelog 2023-01-12 18:02:38.000000000 +0000 +++ python-neutron-lib-3.4.0/debian/changelog 2023-02-21 18:38:35.000000000 +0000 @@ -1,15 +1,22 @@ -python-neutron-lib (3.3.0-0ubuntu1~bpo23.04.1~ppa202301121302) lunar; urgency=medium +python-neutron-lib (3.4.0-0ubuntu1~bpo23.04.1~ppa202302211338) lunar; urgency=medium * No-change backport to lunar. - -- Corey Bryant Thu, 12 Jan 2023 13:02:38 -0500 + -- Corey Bryant Tue, 21 Feb 2023 13:38:35 -0500 + +python-neutron-lib (3.4.0-0ubuntu1) lunar; urgency=medium + + * New upstream release for OpenStack Antelope. + * d/control: Align (Build-)Depends with upstream. + + -- Corey Bryant Tue, 21 Feb 2023 12:17:13 -0500 python-neutron-lib (3.3.0-0ubuntu1) lunar; urgency=medium * New upstream release for OpenStack Antelope. * d/control: Align (Build-)Depends with upstream. - -- Corey Bryant Thu, 12 Jan 2023 12:51:02 -0500 + -- Corey Bryant Thu, 12 Jan 2023 15:26:00 -0500 python-neutron-lib (3.2.0-0ubuntu1) lunar; urgency=medium diff -Nru python-neutron-lib-3.3.0/debian/control python-neutron-lib-3.4.0/debian/control --- python-neutron-lib-3.3.0/debian/control 2023-01-12 17:51:02.000000000 +0000 +++ python-neutron-lib-3.4.0/debian/control 2023-02-21 17:17:13.000000000 +0000 @@ -30,7 +30,7 @@ python3-oslo.db (>= 4.44.0), python3-oslo.i18n (>= 3.20.0), python3-oslo.log (>= 4.3.0), - python3-oslo.messaging (>= 7.0.0), + python3-oslo.messaging (>= 14.2.0), python3-oslo.policy (>= 3.6.2), python3-oslo.serialization (>= 2.25.0), python3-oslo.service (>= 1.24.0), @@ -85,7 +85,7 @@ python3-oslo.db (>= 4.44.0), python3-oslo.i18n (>= 3.20.0), python3-oslo.log (>= 4.3.0), - python3-oslo.messaging (>= 7.0.0), + python3-oslo.messaging (>= 14.2.0), python3-oslo.policy (>= 3.6.2), python3-oslo.serialization (>= 2.25.0), python3-oslo.service (>= 1.24.0), diff -Nru python-neutron-lib-3.3.0/neutron_lib/api/attributes.py python-neutron-lib-3.4.0/neutron_lib/api/attributes.py --- python-neutron-lib-3.3.0/neutron_lib/api/attributes.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/api/attributes.py 2023-02-10 16:29:51.000000000 +0000 @@ -232,7 +232,7 @@ res = validator(res_dict[attr], attr_vals['validate'][rule]) if res: - msg_dict = dict(attr=attr, reason=res) + msg_dict = {'attr': attr, 'reason': res} msg = _("Invalid input for %(attr)s. " "Reason: %(reason)s.") % msg_dict raise exc_cls(msg) diff -Nru python-neutron-lib-3.3.0/neutron_lib/api/definitions/fip_distributed.py python-neutron-lib-3.4.0/neutron_lib/api/definitions/fip_distributed.py --- python-neutron-lib-3.3.0/neutron_lib/api/definitions/fip_distributed.py 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/api/definitions/fip_distributed.py 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,44 @@ +# Copyright (c) 2022 Inspur, Inc. +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +from neutron_lib.api import converters +from neutron_lib.api.definitions import dvr +from neutron_lib.api.definitions import l3 +from neutron_lib import constants + + +ALIAS = 'floating-ip-distributed' +IS_SHIM_EXTENSION = False +IS_STANDARD_ATTR_EXTENSION = False +NAME = 'Floating IP Distributed Extension' +DESCRIPTION = 'Add distributed attribute to Floating IP resource' +UPDATED_TIMESTAMP = '2022-08-30T10:00:00-00:00' +DISTRIBUTED = 'distributed' +RESOURCE_ATTRIBUTE_MAP = { + l3.FLOATINGIPS: { + DISTRIBUTED: { + 'allow_post': True, + 'allow_put': True, + 'convert_to': converters.convert_to_boolean_if_not_none, + 'default': constants.ATTR_NOT_SPECIFIED, + 'is_visible': True, + 'is_filter': True + } + } +} +SUB_RESOURCE_ATTRIBUTE_MAP = {} +ACTION_MAP = {} +REQUIRED_EXTENSIONS = [l3.ALIAS, dvr.ALIAS] +OPTIONAL_EXTENSIONS = [] +ACTION_STATUS = {} diff -Nru python-neutron-lib-3.3.0/neutron_lib/api/definitions/__init__.py python-neutron-lib-3.4.0/neutron_lib/api/definitions/__init__.py --- python-neutron-lib-3.3.0/neutron_lib/api/definitions/__init__.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/api/definitions/__init__.py 2023-02-10 16:29:51.000000000 +0000 @@ -46,6 +46,7 @@ from neutron_lib.api.definitions import extraroute_atomic from neutron_lib.api.definitions import filter_validation from neutron_lib.api.definitions import fip64 +from neutron_lib.api.definitions import fip_distributed from neutron_lib.api.definitions import fip_pf_description from neutron_lib.api.definitions import fip_pf_detail from neutron_lib.api.definitions import fip_pf_port_range @@ -83,6 +84,7 @@ from neutron_lib.api.definitions import pagination from neutron_lib.api.definitions import port from neutron_lib.api.definitions import port_device_profile +from neutron_lib.api.definitions import port_hints from neutron_lib.api.definitions import port_mac_address_override from neutron_lib.api.definitions import port_mac_address_regenerate from neutron_lib.api.definitions import port_numa_affinity_policy @@ -189,6 +191,7 @@ filter_validation, fip64, firewall_v2, + fip_distributed, fip_pf_detail, fip_port_details, flavors, @@ -225,6 +228,7 @@ pagination, port, port_device_profile, + port_hints, port_mac_address_override, port_mac_address_regenerate, port_numa_affinity_policy, diff -Nru python-neutron-lib-3.3.0/neutron_lib/api/definitions/port_hints.py python-neutron-lib-3.4.0/neutron_lib/api/definitions/port_hints.py --- python-neutron-lib-3.3.0/neutron_lib/api/definitions/port_hints.py 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/api/definitions/port_hints.py 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,45 @@ +# Copyright (c) 2023 Ericsson Software Technology +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +from neutron_lib.api.definitions import port + + +ALIAS = 'port-hints' +IS_SHIM_EXTENSION = False +IS_STANDARD_ATTR_EXTENSION = False +NAME = 'Port hints' +DESCRIPTION = 'Backend specific port hints to allow backend specific tuning' +UPDATED_TIMESTAMP = '2023-01-01T00:00:00-00:00' +RESOURCE_NAME = port.RESOURCE_NAME +COLLECTION_NAME = port.COLLECTION_NAME +HINTS = 'hints' + +RESOURCE_ATTRIBUTE_MAP = { + COLLECTION_NAME: { + HINTS: { + 'allow_post': True, + 'allow_put': True, + 'default': None, + 'enforce_policy': True, + 'is_visible': True, + 'validate': {'type:dict_or_none': None}, + }, + }, +} + +SUB_RESOURCE_ATTRIBUTE_MAP = None +ACTION_MAP = {} +ACTION_STATUS = {} +REQUIRED_EXTENSIONS = [] +OPTIONAL_EXTENSIONS = [] diff -Nru python-neutron-lib-3.3.0/neutron_lib/constants.py python-neutron-lib-3.4.0/neutron_lib/constants.py --- python-neutron-lib-3.3.0/neutron_lib/constants.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/constants.py 2023-02-10 16:29:51.000000000 +0000 @@ -41,6 +41,7 @@ ERROR = "ERROR" DEVICE_OWNER_COMPUTE_PREFIX = "compute:" +DEVICE_OWNER_MANILA_PREFIX = "manila:" DEVICE_OWNER_NETWORK_PREFIX = "network:" DEVICE_OWNER_NEUTRON_PREFIX = "neutron:" DEVICE_OWNER_BAREMETAL_PREFIX = "baremetal:" diff -Nru python-neutron-lib-3.3.0/neutron_lib/db/api.py python-neutron-lib-3.4.0/neutron_lib/db/api.py --- python-neutron-lib-3.3.0/neutron_lib/db/api.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/db/api.py 2023-02-10 16:29:51.000000000 +0000 @@ -309,7 +309,7 @@ if session.new: session.flush() - if session.transaction.nested: + if session.get_transaction().nested: # wait until final commit return @@ -479,8 +479,8 @@ if getattr(session, 'autocommit', None): # old behaviour, to be removed with sqlalchemy 2.0 return session.is_active - if not session.transaction: + if not session.get_transaction(): return False - if not session.transaction._connections: + if not session.get_transaction()._connections: return False return True diff -Nru python-neutron-lib-3.3.0/neutron_lib/db/standard_attr.py python-neutron-lib-3.4.0/neutron_lib/db/standard_attr.py --- python-neutron-lib-3.3.0/neutron_lib/db/standard_attr.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/db/standard_attr.py 2023-02-10 16:29:51.000000000 +0000 @@ -214,9 +214,9 @@ raise RuntimeError(_("Model %(sub)s tried to register for API " "resource %(res)s which conflicts with model " "%(other)s.") % - dict(sub=subclass, - other=rs_map[resource], - res=resource)) + {'sub': subclass, + 'other': rs_map[resource], + 'res': resource}) rs_map[resource] = subclass @@ -242,8 +242,8 @@ if collection in parent_map: msg = (_("API parent %(collection)s/%(resource)s for " "model %(subclass)s is already registered.") % - dict(collection=collection, resource=resource, - subclass=subclass)) + {'collection': collection, 'resource': resource, + 'subclass': subclass}) raise RuntimeError(msg) parent_map[collection] = resource return parent_map diff -Nru python-neutron-lib-3.3.0/neutron_lib/db/utils.py python-neutron-lib-3.4.0/neutron_lib/db/utils.py --- python-neutron-lib-3.3.0/neutron_lib/db/utils.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/db/utils.py 2023-02-10 16:29:51.000000000 +0000 @@ -15,7 +15,7 @@ from oslo_db import exception as db_exc from oslo_utils import excutils import sqlalchemy -from sqlalchemy.ext.associationproxy import ASSOCIATION_PROXY +from sqlalchemy.ext import associationproxy from sqlalchemy.orm import exc from sqlalchemy.orm import properties @@ -152,8 +152,14 @@ """ mapper = sqlalchemy.inspect(model) columns = set(c.name for c in mapper.columns) + try: + _association_proxy = associationproxy.ASSOCIATION_PROXY + except AttributeError: + # SQLAlchemy 2.0 + _association_proxy = ( + associationproxy.AssociationProxyExtensionType.ASSOCIATION_PROXY) columns.update(d.value_attr for d in mapper.all_orm_descriptors - if d.extension_type is ASSOCIATION_PROXY) + if d.extension_type is _association_proxy) return dict((k, v) for (k, v) in data.items() if k in columns) diff -Nru python-neutron-lib-3.3.0/neutron_lib/rpc.py python-neutron-lib-3.4.0/neutron_lib/rpc.py --- python-neutron-lib-3.3.0/neutron_lib/rpc.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/rpc.py 2023-02-10 16:29:51.000000000 +0000 @@ -213,10 +213,9 @@ if TRANSPORT is None: raise AssertionError(_("'TRANSPORT' must not be None")) serializer = RequestContextSerializer(serializer) - return BackingOffClient(TRANSPORT, - target, - version_cap=version_cap, - serializer=serializer) + return oslo_messaging.get_rpc_client( + TRANSPORT, target, version_cap=version_cap, + serializer=serializer, client_cls=BackingOffClient) def get_server(target, endpoints, serializer=None): diff -Nru python-neutron-lib-3.3.0/neutron_lib/tests/unit/api/definitions/test_fip_distributed.py python-neutron-lib-3.4.0/neutron_lib/tests/unit/api/definitions/test_fip_distributed.py --- python-neutron-lib-3.3.0/neutron_lib/tests/unit/api/definitions/test_fip_distributed.py 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/tests/unit/api/definitions/test_fip_distributed.py 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,21 @@ +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +from neutron_lib.api.definitions import fip_distributed +from neutron_lib.api.definitions import l3 +from neutron_lib.tests.unit.api.definitions import base + + +class FipDistributedDefinitionTestCase(base.DefinitionBaseTestCase): + extension_module = fip_distributed + extension_resources = (l3.FLOATINGIPS,) + extension_attributes = (fip_distributed.DISTRIBUTED,) diff -Nru python-neutron-lib-3.3.0/neutron_lib/tests/unit/api/definitions/test_port_hints.py python-neutron-lib-3.4.0/neutron_lib/tests/unit/api/definitions/test_port_hints.py --- python-neutron-lib-3.3.0/neutron_lib/tests/unit/api/definitions/test_port_hints.py 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/tests/unit/api/definitions/test_port_hints.py 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,22 @@ +# Copyright 2023 Ericsson Software Technology +# +# Licensed under the Apache License, Version 2.0 (the "License"); you may +# not use this file except in compliance with the License. You may obtain +# a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, WITHOUT +# WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the +# License for the specific language governing permissions and limitations +# under the License. + +from neutron_lib.api.definitions import port_hints +from neutron_lib.tests.unit.api.definitions import base + + +class PortHintsDefinitionTestCase(base.DefinitionBaseTestCase): + extension_module = port_hints + extension_resources = (port_hints.COLLECTION_NAME,) + extension_attributes = (port_hints.HINTS,) diff -Nru python-neutron-lib-3.3.0/neutron_lib/tests/unit/test_rpc.py python-neutron-lib-3.4.0/neutron_lib/tests/unit/test_rpc.py --- python-neutron-lib-3.3.0/neutron_lib/tests/unit/test_rpc.py 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib/tests/unit/test_rpc.py 2023-02-10 16:29:51.000000000 +0000 @@ -104,20 +104,21 @@ rpc.NOTIFICATION_TRANSPORT = mock.Mock() @mock.patch.object(rpc, 'RequestContextSerializer') - @mock.patch.object(rpc, 'BackingOffClient') - def test_get_client(self, mock_client, mock_ser): + @mock.patch.object(messaging, 'get_rpc_client') + def test_get_client(self, mock_get, mock_ser): rpc.TRANSPORT = mock.Mock() tgt = mock.Mock() ser = mock.Mock() - mock_client.return_value = 'client' + mock_get.return_value = 'client' mock_ser.return_value = ser client = rpc.get_client(tgt, version_cap='1.0', serializer='foo') mock_ser.assert_called_once_with('foo') - mock_client.assert_called_once_with(rpc.TRANSPORT, - tgt, version_cap='1.0', - serializer=ser) + mock_get.assert_called_once_with(rpc.TRANSPORT, + tgt, version_cap='1.0', + serializer=ser, + client_cls=rpc.BackingOffClient) self.assertEqual('client', client) @mock.patch.object(rpc, 'RequestContextSerializer') diff -Nru python-neutron-lib-3.3.0/neutron_lib.egg-info/pbr.json python-neutron-lib-3.4.0/neutron_lib.egg-info/pbr.json --- python-neutron-lib-3.3.0/neutron_lib.egg-info/pbr.json 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib.egg-info/pbr.json 2023-02-10 16:30:14.000000000 +0000 @@ -1 +1 @@ -{"git_version": "f2bb7c7", "is_release": true} \ No newline at end of file +{"git_version": "23fa6b3", "is_release": true} \ No newline at end of file diff -Nru python-neutron-lib-3.3.0/neutron_lib.egg-info/PKG-INFO python-neutron-lib-3.4.0/neutron_lib.egg-info/PKG-INFO --- python-neutron-lib-3.3.0/neutron_lib.egg-info/PKG-INFO 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib.egg-info/PKG-INFO 2023-02-10 16:30:14.000000000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: neutron-lib -Version: 3.3.0 +Version: 3.4.0 Summary: Neutron shared routines and utilities Home-page: https://docs.openstack.org/neutron-lib/latest/ Author: OpenStack diff -Nru python-neutron-lib-3.3.0/neutron_lib.egg-info/requires.txt python-neutron-lib-3.4.0/neutron_lib.egg-info/requires.txt --- python-neutron-lib-3.3.0/neutron_lib.egg-info/requires.txt 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib.egg-info/requires.txt 2023-02-10 16:30:14.000000000 +0000 @@ -10,7 +10,7 @@ oslo.db>=4.44.0 oslo.i18n>=3.20.0 oslo.log>=4.3.0 -oslo.messaging>=7.0.0 +oslo.messaging>=14.2.0 oslo.policy>=3.6.2 oslo.serialization>=2.25.0 oslo.service!=1.28.1,>=1.24.0 diff -Nru python-neutron-lib-3.3.0/neutron_lib.egg-info/SOURCES.txt python-neutron-lib-3.4.0/neutron_lib.egg-info/SOURCES.txt --- python-neutron-lib-3.3.0/neutron_lib.egg-info/SOURCES.txt 2023-01-04 13:41:59.000000000 +0000 +++ python-neutron-lib-3.4.0/neutron_lib.egg-info/SOURCES.txt 2023-02-10 16:30:15.000000000 +0000 @@ -21,6 +21,7 @@ api-ref/source/v2/agents.inc api-ref/source/v2/auto-topology.inc api-ref/source/v2/availability_zones.inc +api-ref/source/v2/bgp_dragent_scheduler.inc api-ref/source/v2/bgp_peer.inc api-ref/source/v2/bgp_speaker.inc api-ref/source/v2/bgpvpn-bgpvpns.inc @@ -115,7 +116,11 @@ api-ref/source/v2/samples/bgp/bgp_speaker_add_peer-response.json api-ref/source/v2/samples/bgp/bgp_speaker_list_dragent_host-response.json api-ref/source/v2/samples/bgp/bgp_speaker_list_routes-response.json +api-ref/source/v2/samples/bgp/bgp_speaker_remove_network-request.json api-ref/source/v2/samples/bgp/bgp_speaker_remove_peer-request.json +api-ref/source/v2/samples/bgp/dragent_add_speaker-request.json +api-ref/source/v2/samples/bgp/dragent_list_agents_hosting_speaker-response.json +api-ref/source/v2/samples/bgp/dragent_list_speakers-response.json api-ref/source/v2/samples/bgpvpn/bgpvpns/bgpvpn-create-request.json api-ref/source/v2/samples/bgpvpn/bgpvpns/bgpvpn-create-response.json api-ref/source/v2/samples/bgpvpn/bgpvpns/bgpvpn-show-response.json @@ -569,6 +574,7 @@ neutron_lib/api/definitions/extraroute_atomic.py neutron_lib/api/definitions/filter_validation.py neutron_lib/api/definitions/fip64.py +neutron_lib/api/definitions/fip_distributed.py neutron_lib/api/definitions/fip_pf_description.py neutron_lib/api/definitions/fip_pf_detail.py neutron_lib/api/definitions/fip_pf_port_range.py @@ -606,6 +612,7 @@ neutron_lib/api/definitions/pagination.py neutron_lib/api/definitions/port.py neutron_lib/api/definitions/port_device_profile.py +neutron_lib/api/definitions/port_hints.py neutron_lib/api/definitions/port_mac_address_override.py neutron_lib/api/definitions/port_mac_address_regenerate.py neutron_lib/api/definitions/port_numa_affinity_policy.py @@ -818,6 +825,7 @@ neutron_lib/tests/unit/api/definitions/test_extraroute_atomic.py neutron_lib/tests/unit/api/definitions/test_filter_validation.py neutron_lib/tests/unit/api/definitions/test_fip64.py +neutron_lib/tests/unit/api/definitions/test_fip_distributed.py neutron_lib/tests/unit/api/definitions/test_fip_port_details.py neutron_lib/tests/unit/api/definitions/test_firewall_v2.py neutron_lib/tests/unit/api/definitions/test_flavors.py @@ -853,6 +861,7 @@ neutron_lib/tests/unit/api/definitions/test_pagination.py neutron_lib/tests/unit/api/definitions/test_port.py neutron_lib/tests/unit/api/definitions/test_port_device_profile.py +neutron_lib/tests/unit/api/definitions/test_port_hints.py neutron_lib/tests/unit/api/definitions/test_port_mac_address_regenerate.py neutron_lib/tests/unit/api/definitions/test_port_numa_affinity_policy.py neutron_lib/tests/unit/api/definitions/test_port_resource_request.py @@ -1001,6 +1010,7 @@ releasenotes/notes/add-extension-supported-be6f7069856d2891.yaml releasenotes/notes/add-extension-uplink-status-propagation-6b6050d6609c19c8.yaml releasenotes/notes/add-filter-validation-api-extension-15cc667d5498f163.yaml +releasenotes/notes/add-fip-distributed-extension-ce44e8df264d44b6.yaml releasenotes/notes/add-fip-pf-detail-extension-fa8cd3b3857901d7.yaml releasenotes/notes/add-floatingip-pools-extension-17a1ee5c7eafc989.yaml releasenotes/notes/add-ip-hopopt-to-protocol-dictionary-3cbe54bb5056f790.yaml @@ -1150,6 +1160,7 @@ releasenotes/notes/policy-redux-25c26836219fd02d.yaml releasenotes/notes/populate-dict-defaults-3f205c414f21bf54.yaml releasenotes/notes/port-device-profile-ffa9628ef6395c68.yaml +releasenotes/notes/port-hints-8273fa5b7454a8ef.yaml releasenotes/notes/port-mac-address-regenerate-cc33d03216b5bc3d.yaml releasenotes/notes/port-mac-sanitization-d2b6ee77b66cb815.yaml releasenotes/notes/port-numa-affinity-policy-9e6d1bafd3c6af36.yaml diff -Nru python-neutron-lib-3.3.0/PKG-INFO python-neutron-lib-3.4.0/PKG-INFO --- python-neutron-lib-3.3.0/PKG-INFO 2023-01-04 13:41:59.950168400 +0000 +++ python-neutron-lib-3.4.0/PKG-INFO 2023-02-10 16:30:15.293515000 +0000 @@ -1,6 +1,6 @@ Metadata-Version: 1.2 Name: neutron-lib -Version: 3.3.0 +Version: 3.4.0 Summary: Neutron shared routines and utilities Home-page: https://docs.openstack.org/neutron-lib/latest/ Author: OpenStack diff -Nru python-neutron-lib-3.3.0/releasenotes/notes/add-fip-distributed-extension-ce44e8df264d44b6.yaml python-neutron-lib-3.4.0/releasenotes/notes/add-fip-distributed-extension-ce44e8df264d44b6.yaml --- python-neutron-lib-3.3.0/releasenotes/notes/add-fip-distributed-extension-ce44e8df264d44b6.yaml 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/releasenotes/notes/add-fip-distributed-extension-ce44e8df264d44b6.yaml 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,5 @@ +--- +features: + - | + Add API extension ``floating-ip-distributed``. This extension + adds ``distributed`` attribute to the Floating IP resource. diff -Nru python-neutron-lib-3.3.0/releasenotes/notes/port-hints-8273fa5b7454a8ef.yaml python-neutron-lib-3.4.0/releasenotes/notes/port-hints-8273fa5b7454a8ef.yaml --- python-neutron-lib-3.3.0/releasenotes/notes/port-hints-8273fa5b7454a8ef.yaml 1970-01-01 00:00:00.000000000 +0000 +++ python-neutron-lib-3.4.0/releasenotes/notes/port-hints-8273fa5b7454a8ef.yaml 2023-02-10 16:29:51.000000000 +0000 @@ -0,0 +1,11 @@ +--- +features: + - | + The port hints extension (``port-hints``) introduces the ``hints`` + port attribute. Hints are backend specific pieces of information, + mainly to allow backend specific performance tuning. In itself this + extension defines no particular hint, and therefore no valid values + of the ``hints`` attribute. It just serves as the base for other + extensions introducing concrete hints and signals the presence of + the ``hints`` port attribute to the API user. By default policy, + use of the ``hints`` attribute is restricted to admininstrative users. diff -Nru python-neutron-lib-3.3.0/requirements.txt python-neutron-lib-3.4.0/requirements.txt --- python-neutron-lib-3.3.0/requirements.txt 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/requirements.txt 2023-02-10 16:29:51.000000000 +0000 @@ -20,7 +20,7 @@ oslo.db>=4.44.0 # Apache-2.0 oslo.i18n>=3.20.0 # Apache-2.0 oslo.log>=4.3.0 # Apache-2.0 -oslo.messaging>=7.0.0 # Apache-2.0 +oslo.messaging>=14.2.0 # Apache-2.0 oslo.policy>=3.6.2 # Apache-2.0 oslo.serialization>=2.25.0 # Apache-2.0 oslo.service!=1.28.1,>=1.24.0 # Apache-2.0 diff -Nru python-neutron-lib-3.3.0/tox.ini python-neutron-lib-3.4.0/tox.ini --- python-neutron-lib-3.3.0/tox.ini 2023-01-04 13:41:30.000000000 +0000 +++ python-neutron-lib-3.4.0/tox.ini 2023-02-10 16:29:51.000000000 +0000 @@ -1,11 +1,10 @@ [tox] minversion = 3.18.0 -envlist = py38,pep8 -skipsdist = True +envlist = py3,pep8,docs ignore_basepython_conflict = True [testenv] -basepython = python3 +basepython = {env:TOX_PYTHON:python3} usedevelop = True passenv = TRACE_FAILONLY setenv = @@ -17,15 +16,15 @@ -c{env:TOX_CONSTRAINTS_FILE:https://releases.openstack.org/constraints/upper/master} -r{toxinidir}/requirements.txt -r{toxinidir}/test-requirements.txt -allowlist_externals = sh +allowlist_externals = bash commands = stestr run {posargs} [testenv:pep8] commands = flake8 - {toxinidir}/tools/check_samples.sh - sh ./tools/coding-checks.sh --pylint '{posargs}' + bash {toxinidir}/tools/check_samples.sh + bash ./tools/coding-checks.sh --pylint '{posargs}' {[testenv:bandit]commands} [testenv:releasenotes] @@ -91,7 +90,7 @@ [testenv:api-report] commands = - {toxinidir}/tools/api_report.sh + bash {toxinidir}/tools/api_report.sh [flake8] # H106: Don't put vim configuration in source files @@ -99,7 +98,7 @@ # H204: Use assert(Not)Equal to check for equality # H205: Use assert(Greater|Less)(Equal) for comparison # H904: Delay string interpolations at logging calls -enable-extensions=H106,H203,H204,H205,H904 +enable-extensions = H106,H203,H204,H205,H904 show-source = True exclude=.venv,.git,.tox,dist,doc,*lib/python*,*egg,build,tools import-order-style = pep8