]> review.fuel-infra Code Review - openstack-build/neutron-build.git/commitdiff
NSX: Move DB models as part of core vendor decomposition
authorAbhishek Raut <rauta@vmware.com>
Mon, 10 Aug 2015 16:54:05 +0000 (09:54 -0700)
committerAbhishek Raut <rauta@vmware.com>
Mon, 17 Aug 2015 19:19:53 +0000 (19:19 +0000)
This patch removes the database models from neutron repo.
Also removes README, common modules and plugin module.

Change-Id: I5d5b0acf34417889c2a449f22b92fd105697d90d
Related-Blueprint: core-vendor-decomposition
Partial-bug: #1483453

neutron/db/migration/alembic_migrations/external.py
neutron/db/migration/models/head.py
neutron/plugins/vmware/README [deleted file]
neutron/plugins/vmware/common/__init__.py [deleted file]
neutron/plugins/vmware/common/nsxv_constants.py [deleted file]
neutron/plugins/vmware/dbexts/__init__.py [deleted file]
neutron/plugins/vmware/dbexts/nsx_models.py [deleted file]
neutron/plugins/vmware/dbexts/nsxv_models.py [deleted file]
neutron/plugins/vmware/dbexts/vcns_models.py [deleted file]
neutron/plugins/vmware/plugin.py [deleted file]
setup.cfg

index 3f337c04b5927521571f48daeba7429285878c04..7bd9ae81a1a9163a2f0f974c85358ac667e219a1 100644 (file)
@@ -40,6 +40,38 @@ DRIVER_TABLES = [
     'cisco_ml2_n1kv_vxlan_allocations',
     'cisco_ml2_n1kv_vlan_allocations',
     'cisco_ml2_n1kv_profile_bindings',
+    # VMware-NSX models moved to openstack/vmware-nsx
+    'tz_network_bindings',
+    'neutron_nsx_network_mappings',
+    'neutron_nsx_security_group_mappings',
+    'neutron_nsx_port_mappings',
+    'neutron_nsx_router_mappings',
+    'multi_provider_networks',
+    'networkconnections',
+    'networkgatewaydevicereferences',
+    'networkgatewaydevices',
+    'networkgateways',
+    'maclearningstates',
+    'qosqueues',
+    'portqueuemappings',
+    'networkqueuemappings',
+    'lsn_port',
+    'lsn',
+    'nsxv_router_bindings',
+    'nsxv_edge_vnic_bindings',
+    'nsxv_edge_dhcp_static_bindings',
+    'nsxv_internal_networks',
+    'nsxv_internal_edges',
+    'nsxv_security_group_section_mappings',
+    'nsxv_rule_mappings',
+    'nsxv_port_vnic_mappings',
+    'nsxv_router_ext_attributes',
+    'nsxv_tz_network_bindings',
+    'nsxv_port_index_mappings',
+    'nsxv_firewall_rule_bindings',
+    'nsxv_spoofguard_policy_network_mappings',
+    'nsxv_vdr_dhcp_bindings',
+    'vcns_router_bindings',
     # Add your tables with moved models here^. Please end with a comma.
 ]
 
index 3c3da37b35ea6a92c79ec2620f41b3e0329ca3da..75d7242bbb27e7a53a4d803839c367f485451ba9 100644 (file)
@@ -65,9 +65,6 @@ from neutron.plugins.ml2.drivers import type_vxlan  # noqa
 from neutron.plugins.ml2 import models  # noqa
 from neutron.plugins.nec.db import models as nec_models  # noqa
 from neutron.plugins.nuage import nuage_models  # noqa
-from neutron.plugins.vmware.dbexts import nsx_models  # noqa
-from neutron.plugins.vmware.dbexts import nsxv_models  # noqa
-from neutron.plugins.vmware.dbexts import vcns_models  # noqa
 
 
 def get_metadata():
diff --git a/neutron/plugins/vmware/README b/neutron/plugins/vmware/README
deleted file mode 100644 (file)
index fac9354..0000000
+++ /dev/null
@@ -1,14 +0,0 @@
-VMware Neutron plugins
-===========================
-
-Neutron plugins for VMware NSX family products
-
-* For configuration information, supported extensions, and architectural
-  documentation please refer to the plugin wiki page:
-  https://wiki.openstack.org/wiki/Neutron/VMware_NSX_plugins
-
-* Full plugin code available at:
-  * http://git.openstack.org/cgit/openstack/vmware-nsx
-  * https://github.com/openstack/vmware-nsx
-
-* Pypi location: https://pypi.python.org/pypi/vmware-nsx
diff --git a/neutron/plugins/vmware/common/__init__.py b/neutron/plugins/vmware/common/__init__.py
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/neutron/plugins/vmware/common/nsxv_constants.py b/neutron/plugins/vmware/common/nsxv_constants.py
deleted file mode 100644 (file)
index 3d1ae85..0000000
+++ /dev/null
@@ -1,28 +0,0 @@
-# Copyright 2015 VMware, Inc.
-# All Rights Reserved
-#
-# 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.
-
-# Edge size
-COMPACT = 'compact'
-LARGE = 'large'
-XLARGE = 'xlarge'
-QUADLARGE = 'quadlarge'
-
-
-# Edge type
-SERVICE_EDGE = 'service'
-VDR_EDGE = 'vdr'
-
-# Internal element purpose
-INTER_EDGE_PURPOSE = 'inter_edge_net'
diff --git a/neutron/plugins/vmware/dbexts/__init__.py b/neutron/plugins/vmware/dbexts/__init__.py
deleted file mode 100644 (file)
index e69de29..0000000
diff --git a/neutron/plugins/vmware/dbexts/nsx_models.py b/neutron/plugins/vmware/dbexts/nsx_models.py
deleted file mode 100644 (file)
index 7ca6713..0000000
+++ /dev/null
@@ -1,274 +0,0 @@
-# Copyright 2015 VMware, 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.
-
-"""
-NSX data models.
-
-This module defines data models used by the VMware NSX plugin family.
-
-"""
-
-import sqlalchemy as sa
-from sqlalchemy import orm
-from sqlalchemy import sql
-
-from neutron.db import model_base
-from neutron.db import models_v2
-
-
-class TzNetworkBinding(model_base.BASEV2):
-    """Represents a binding of a virtual network with a transport zone.
-
-    This model class associates a Neutron network with a transport zone;
-    optionally a vlan ID might be used if the binding type is 'bridge'
-    """
-    __tablename__ = 'tz_network_bindings'
-
-    # TODO(arosen) - it might be worth while refactoring the how this data
-    # is stored later so every column does not need to be a primary key.
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete="CASCADE"),
-                           primary_key=True)
-    # 'flat', 'vlan', stt' or 'gre'
-    binding_type = sa.Column(sa.Enum('flat', 'vlan', 'stt', 'gre', 'l3_ext',
-                             name='tz_network_bindings_binding_type'),
-                             nullable=False, primary_key=True)
-    phy_uuid = sa.Column(sa.String(36), primary_key=True, default='')
-    vlan_id = sa.Column(sa.Integer, primary_key=True,
-                        autoincrement=False, default=0)
-
-    def __init__(self, network_id, binding_type, phy_uuid, vlan_id):
-        self.network_id = network_id
-        self.binding_type = binding_type
-        self.phy_uuid = phy_uuid
-        self.vlan_id = vlan_id
-
-    def __repr__(self):
-        return "<NetworkBinding(%s,%s,%s,%s)>" % (self.network_id,
-                                                  self.binding_type,
-                                                  self.phy_uuid,
-                                                  self.vlan_id)
-
-
-class NeutronNsxNetworkMapping(model_base.BASEV2):
-    """Maps neutron network identifiers to NSX identifiers.
-
-    Because of chained logical switches more than one mapping might exist
-    for a single Neutron network.
-    """
-    __tablename__ = 'neutron_nsx_network_mappings'
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete='CASCADE'),
-                           primary_key=True)
-    nsx_id = sa.Column(sa.String(36), primary_key=True)
-
-
-class NeutronNsxSecurityGroupMapping(model_base.BASEV2):
-    """Backend mappings for Neutron Security Group identifiers.
-
-    This class maps a neutron security group identifier to the corresponding
-    NSX security profile identifier.
-    """
-
-    __tablename__ = 'neutron_nsx_security_group_mappings'
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('securitygroups.id',
-                                         ondelete="CASCADE"),
-                           primary_key=True)
-    nsx_id = sa.Column(sa.String(36), primary_key=True)
-
-
-class NeutronNsxPortMapping(model_base.BASEV2):
-    """Represents the mapping between neutron and nsx port uuids."""
-
-    __tablename__ = 'neutron_nsx_port_mappings'
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('ports.id', ondelete="CASCADE"),
-                           primary_key=True)
-    nsx_switch_id = sa.Column(sa.String(36))
-    nsx_port_id = sa.Column(sa.String(36), nullable=False)
-
-    def __init__(self, neutron_id, nsx_switch_id, nsx_port_id):
-        self.neutron_id = neutron_id
-        self.nsx_switch_id = nsx_switch_id
-        self.nsx_port_id = nsx_port_id
-
-
-class NeutronNsxRouterMapping(model_base.BASEV2):
-    """Maps neutron router identifiers to NSX identifiers."""
-    __tablename__ = 'neutron_nsx_router_mappings'
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('routers.id', ondelete='CASCADE'),
-                           primary_key=True)
-    nsx_id = sa.Column(sa.String(36))
-
-
-class MultiProviderNetworks(model_base.BASEV2):
-    """Networks provisioned through multiprovider extension."""
-
-    __tablename__ = 'multi_provider_networks'
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete="CASCADE"),
-                           primary_key=True)
-
-    def __init__(self, network_id):
-        self.network_id = network_id
-
-
-class NetworkConnection(model_base.BASEV2, models_v2.HasTenant):
-    """Defines a connection between a network gateway and a network."""
-    # We use port_id as the primary key as one can connect a gateway
-    # to a network in multiple ways (and we cannot use the same port form
-    # more than a single gateway)
-    network_gateway_id = sa.Column(sa.String(36),
-                                   sa.ForeignKey('networkgateways.id',
-                                                 ondelete='CASCADE'))
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete='CASCADE'))
-    segmentation_type = sa.Column(
-        sa.Enum('flat', 'vlan',
-                name='networkconnections_segmentation_type'))
-    segmentation_id = sa.Column(sa.Integer)
-    __table_args__ = (sa.UniqueConstraint(network_gateway_id,
-                                          segmentation_type,
-                                          segmentation_id),
-                      model_base.BASEV2.__table_args__)
-    # Also, storing port id comes back useful when disconnecting a network
-    # from a gateway
-    port_id = sa.Column(sa.String(36),
-                        sa.ForeignKey('ports.id', ondelete='CASCADE'),
-                        primary_key=True)
-
-
-class NetworkGatewayDeviceReference(model_base.BASEV2):
-    id = sa.Column(sa.String(36), primary_key=True)
-    network_gateway_id = sa.Column(sa.String(36),
-                                   sa.ForeignKey('networkgateways.id',
-                                                 ondelete='CASCADE'),
-                                   primary_key=True)
-    interface_name = sa.Column(sa.String(64), primary_key=True)
-
-
-class NetworkGatewayDevice(model_base.BASEV2, models_v2.HasId,
-                           models_v2.HasTenant):
-    nsx_id = sa.Column(sa.String(36))
-    # Optional name for the gateway device
-    name = sa.Column(sa.String(255))
-    # Transport connector type. Not using enum as range of
-    # connector types might vary with backend version
-    connector_type = sa.Column(sa.String(10))
-    # Transport connector IP Address
-    connector_ip = sa.Column(sa.String(64))
-    # operational status
-    status = sa.Column(sa.String(16))
-
-
-class NetworkGateway(model_base.BASEV2, models_v2.HasId,
-                     models_v2.HasTenant):
-    """Defines the data model for a network gateway."""
-    name = sa.Column(sa.String(255))
-    # Tenant id is nullable for this resource
-    tenant_id = sa.Column(sa.String(36))
-    default = sa.Column(sa.Boolean())
-    devices = orm.relationship(NetworkGatewayDeviceReference,
-                               backref='networkgateways',
-                               cascade='all,delete')
-    network_connections = orm.relationship(NetworkConnection, lazy='joined')
-
-
-class MacLearningState(model_base.BASEV2):
-
-    port_id = sa.Column(sa.String(36),
-                        sa.ForeignKey('ports.id', ondelete="CASCADE"),
-                        primary_key=True)
-    mac_learning_enabled = sa.Column(sa.Boolean(), nullable=False)
-
-    # Add a relationship to the Port model using the backref attribute.
-    # This will instruct SQLAlchemy to eagerly load this association.
-    port = orm.relationship(
-        models_v2.Port,
-        backref=orm.backref("mac_learning_state", lazy='joined',
-                            uselist=False, cascade='delete'))
-
-
-class LsnPort(models_v2.model_base.BASEV2):
-
-    __tablename__ = 'lsn_port'
-
-    lsn_port_id = sa.Column(sa.String(36), primary_key=True)
-
-    lsn_id = sa.Column(sa.String(36),
-                       sa.ForeignKey('lsn.lsn_id', ondelete="CASCADE"),
-                       nullable=False)
-    sub_id = sa.Column(sa.String(36), nullable=False, unique=True)
-    mac_addr = sa.Column(sa.String(32), nullable=False, unique=True)
-
-    def __init__(self, lsn_port_id, subnet_id, mac_address, lsn_id):
-        self.lsn_port_id = lsn_port_id
-        self.lsn_id = lsn_id
-        self.sub_id = subnet_id
-        self.mac_addr = mac_address
-
-
-class Lsn(models_v2.model_base.BASEV2):
-    __tablename__ = 'lsn'
-
-    lsn_id = sa.Column(sa.String(36), primary_key=True)
-    net_id = sa.Column(sa.String(36), nullable=False)
-
-    def __init__(self, net_id, lsn_id):
-        self.net_id = net_id
-        self.lsn_id = lsn_id
-
-
-class QoSQueue(model_base.BASEV2, models_v2.HasId, models_v2.HasTenant):
-    name = sa.Column(sa.String(255))
-    default = sa.Column(sa.Boolean, default=False, server_default=sql.false())
-    min = sa.Column(sa.Integer, nullable=False)
-    max = sa.Column(sa.Integer, nullable=True)
-    qos_marking = sa.Column(sa.Enum('untrusted', 'trusted',
-                                    name='qosqueues_qos_marking'))
-    dscp = sa.Column(sa.Integer)
-
-
-class PortQueueMapping(model_base.BASEV2):
-    port_id = sa.Column(sa.String(36),
-                        sa.ForeignKey("ports.id", ondelete="CASCADE"),
-                        primary_key=True)
-
-    queue_id = sa.Column(sa.String(36), sa.ForeignKey("qosqueues.id"),
-                         primary_key=True)
-
-    # Add a relationship to the Port model adding a backref which will
-    # allow SQLAlchemy for eagerly load the queue binding
-    port = orm.relationship(
-        models_v2.Port,
-        backref=orm.backref("qos_queue", uselist=False,
-                            cascade='delete', lazy='joined'))
-
-
-class NetworkQueueMapping(model_base.BASEV2):
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey("networks.id", ondelete="CASCADE"),
-                           primary_key=True)
-
-    queue_id = sa.Column(sa.String(36), sa.ForeignKey("qosqueues.id",
-                                                      ondelete="CASCADE"))
-
-    # Add a relationship to the Network model adding a backref which will
-    # allow SQLAlcremy for eagerly load the queue binding
-    network = orm.relationship(
-        models_v2.Network,
-        backref=orm.backref("qos_queue", uselist=False,
-                            cascade='delete', lazy='joined'))
diff --git a/neutron/plugins/vmware/dbexts/nsxv_models.py b/neutron/plugins/vmware/dbexts/nsxv_models.py
deleted file mode 100644 (file)
index 2edb400..0000000
+++ /dev/null
@@ -1,258 +0,0 @@
-# Copyright 2015 VMware, Inc.
-#
-# All Rights Reserved.
-#
-#    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.
-
-
-import sqlalchemy as sa
-from sqlalchemy import orm
-
-from neutron.db import l3_db
-from neutron.db import model_base
-from neutron.db import models_v2
-from neutron.plugins.vmware.common import nsxv_constants
-
-
-class NsxvRouterBinding(model_base.BASEV2, models_v2.HasStatusDescription):
-    """Represents the mapping between neutron router and vShield Edge."""
-
-    __tablename__ = 'nsxv_router_bindings'
-
-    # no ForeignKey to routers.id because for now, a router can be removed
-    # from routers when delete_router is executed, but the binding is only
-    # removed after the Edge is deleted
-    router_id = sa.Column(sa.String(36),
-                          primary_key=True)
-    edge_id = sa.Column(sa.String(36),
-                        nullable=True)
-    lswitch_id = sa.Column(sa.String(36),
-                           nullable=True)
-    appliance_size = sa.Column(sa.Enum(
-        nsxv_constants.COMPACT,
-        nsxv_constants.LARGE,
-        nsxv_constants.XLARGE,
-        nsxv_constants.QUADLARGE,
-        name='nsxv_router_bindings_appliance_size'))
-    edge_type = sa.Column(sa.Enum(nsxv_constants.SERVICE_EDGE,
-                                  nsxv_constants.VDR_EDGE,
-                                  name='nsxv_router_bindings_edge_type'))
-
-
-class NsxvEdgeVnicBinding(model_base.BASEV2):
-    """Represents mapping between vShield Edge vnic and neutron netowrk."""
-
-    __tablename__ = 'nsxv_edge_vnic_bindings'
-
-    edge_id = sa.Column(sa.String(36),
-                        primary_key=True)
-    vnic_index = sa.Column(sa.Integer(),
-                           primary_key=True)
-    tunnel_index = sa.Column(sa.Integer(),
-                             primary_key=True)
-    network_id = sa.Column(sa.String(36), nullable=True)
-
-
-class NsxvEdgeDhcpStaticBinding(model_base.BASEV2):
-    """Represents mapping between mac addr and bindingId."""
-
-    __tablename__ = 'nsxv_edge_dhcp_static_bindings'
-
-    edge_id = sa.Column(sa.String(36), primary_key=True)
-    mac_address = sa.Column(sa.String(32), primary_key=True)
-    binding_id = sa.Column(sa.String(36), nullable=False)
-
-
-class NsxvInternalNetworks(model_base.BASEV2):
-    """Represents internal networks between NSXV plugin elements."""
-
-    __tablename__ = 'nsxv_internal_networks'
-
-    network_purpose = sa.Column(
-        sa.Enum(nsxv_constants.INTER_EDGE_PURPOSE,
-                name='nsxv_internal_networks_purpose'),
-        primary_key=True)
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey("networks.id", ondelete="CASCADE"),
-                           nullable=True)
-
-
-class NsxvInternalEdges(model_base.BASEV2):
-    """Represents internal Edge appliances for NSXV plugin operations."""
-
-    __tablename__ = 'nsxv_internal_edges'
-
-    ext_ip_address = sa.Column(sa.String(64), primary_key=True)
-    router_id = sa.Column(sa.String(36), nullable=True)
-    purpose = sa.Column(
-        sa.Enum(nsxv_constants.INTER_EDGE_PURPOSE,
-                name='nsxv_internal_edges_purpose'))
-
-
-class NsxvSecurityGroupSectionMapping(model_base.BASEV2):
-    """Backend mappings for Neutron Rule Sections.
-
-    This class maps a neutron security group identifier to the corresponding
-    NSX layer 3 section.
-    """
-
-    __tablename__ = 'nsxv_security_group_section_mappings'
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('securitygroups.id',
-                                         ondelete="CASCADE"),
-                           primary_key=True)
-    ip_section_id = sa.Column(sa.String(100))
-
-
-class NsxvRuleMapping(model_base.BASEV2):
-    """Backend mappings for Neutron Rule Sections.
-
-    This class maps a neutron security group identifier to the corresponding
-    NSX layer 3 and layer 2 sections.
-    """
-
-    __tablename__ = 'nsxv_rule_mappings'
-
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('securitygrouprules.id',
-                                         ondelete="CASCADE"),
-                           primary_key=True)
-    nsx_rule_id = sa.Column(sa.String(36), primary_key=True)
-
-
-class NsxvPortVnicMapping(model_base.BASEV2):
-    """Maps neutron port to NSXv VM Vnic Id."""
-
-    __tablename__ = 'nsxv_port_vnic_mappings'
-
-    neutron_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('ports.id', ondelete="CASCADE"),
-                           primary_key=True)
-    nsx_id = sa.Column(sa.String(42), primary_key=True)
-
-
-class NsxvRouterExtAttributes(model_base.BASEV2):
-    """Router attributes managed by NSX plugin extensions."""
-
-    __tablename__ = 'nsxv_router_ext_attributes'
-
-    router_id = sa.Column(sa.String(36),
-                          sa.ForeignKey('routers.id', ondelete="CASCADE"),
-                          primary_key=True)
-    distributed = sa.Column(sa.Boolean, default=False, nullable=False)
-    router_type = sa.Column(
-        sa.Enum('shared', 'exclusive',
-                name='nsxv_router_type'),
-        default='exclusive', nullable=False)
-    service_router = sa.Column(sa.Boolean, default=False, nullable=False)
-    # Add a relationship to the Router model in order to instruct
-    # SQLAlchemy to eagerly load this association
-    router = orm.relationship(
-        l3_db.Router,
-        backref=orm.backref("nsx_attributes", lazy='joined',
-                            uselist=False, cascade='delete'))
-
-
-class NsxvTzNetworkBinding(model_base.BASEV2):
-    """Represents a binding of a virtual network with a transport zone.
-
-    This model class associates a Neutron network with a transport zone;
-    optionally a vlan ID might be used if the binding type is 'bridge'
-    """
-
-    __tablename__ = 'nsxv_tz_network_bindings'
-
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete="CASCADE"),
-                           primary_key=True)
-    binding_type = sa.Column(
-        sa.Enum('flat', 'vlan', 'portgroup',
-                name='nsxv_tz_network_bindings_binding_type'),
-        nullable=False, primary_key=True)
-    phy_uuid = sa.Column(sa.String(36), primary_key=True, nullable=True)
-    vlan_id = sa.Column(sa.Integer, primary_key=True, nullable=True,
-                        autoincrement=False)
-
-    def __init__(self, network_id, binding_type, phy_uuid, vlan_id):
-        self.network_id = network_id
-        self.binding_type = binding_type
-        self.phy_uuid = phy_uuid
-        self.vlan_id = vlan_id
-
-    def __repr__(self):
-        return "<NsxvTzNetworkBinding(%s,%s,%s,%s)>" % (self.network_id,
-                                                        self.binding_type,
-                                                        self.phy_uuid,
-                                                        self.vlan_id)
-
-
-class NsxvPortIndexMapping(model_base.BASEV2):
-    """Associates attached Neutron ports with the instance VNic index."""
-
-    __tablename__ = 'nsxv_port_index_mappings'
-
-    port_id = sa.Column(sa.String(36),
-                        sa.ForeignKey('ports.id', ondelete="CASCADE"),
-                        primary_key=True)
-    device_id = sa.Column(sa.String(255), nullable=False)
-    index = sa.Column(sa.Integer, nullable=False)
-    __table_args__ = (sa.UniqueConstraint(device_id, index),
-                      model_base.BASEV2.__table_args__)
-
-    # Add a relationship to the Port model in order to instruct SQLAlchemy to
-    # eagerly read port vnic-index
-    port = orm.relationship(
-        models_v2.Port,
-        backref=orm.backref("vnic_index", lazy='joined',
-                            uselist=False, cascade='delete'))
-
-
-class NsxvEdgeFirewallRuleBinding(model_base.BASEV2):
-    """Mapping between firewall rule and edge firewall rule_id."""
-
-    __tablename__ = 'nsxv_firewall_rule_bindings'
-
-    rule_id = sa.Column(sa.String(36),
-                        primary_key=True)
-    edge_id = sa.Column(sa.String(36), primary_key=True)
-    rule_vse_id = sa.Column(sa.String(36))
-
-
-class NsxvSpoofGuardPolicyNetworkMapping(model_base.BASEV2):
-    """Mapping between SpoofGuard and neutron networks"""
-
-    __tablename__ = 'nsxv_spoofguard_policy_network_mappings'
-
-    network_id = sa.Column(sa.String(36),
-                           sa.ForeignKey('networks.id', ondelete='CASCADE'),
-                           primary_key=True,
-                           nullable=False)
-    policy_id = sa.Column(sa.String(36), nullable=False)
-
-
-class NsxvVdrDhcpBinding(model_base.BASEV2):
-    """1:1 mapping between VDR and a DHCP Edge."""
-
-    __tablename__ = 'nsxv_vdr_dhcp_bindings'
-
-    vdr_router_id = sa.Column(sa.String(36), primary_key=True)
-    dhcp_router_id = sa.Column(sa.String(36), nullable=False)
-    dhcp_edge_id = sa.Column(sa.String(36), nullable=False)
-
-    __table_args__ = (
-        sa.UniqueConstraint(
-            dhcp_router_id,
-            name='unique_nsxv_vdr_dhcp_bindings0dhcp_router_id'),
-        sa.UniqueConstraint(
-            dhcp_edge_id,
-            name='unique_nsxv_vdr_dhcp_bindings0dhcp_edge_id'))
diff --git a/neutron/plugins/vmware/dbexts/vcns_models.py b/neutron/plugins/vmware/dbexts/vcns_models.py
deleted file mode 100644 (file)
index 5044743..0000000
+++ /dev/null
@@ -1,37 +0,0 @@
-# Copyright 2013 VMware, Inc.
-#
-# All Rights Reserved.
-#
-#    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.
-
-
-import sqlalchemy as sa
-
-from neutron.db import model_base
-from neutron.db import models_v2
-
-
-class VcnsRouterBinding(model_base.BASEV2, models_v2.HasStatusDescription):
-    """Represents the mapping between neutron router and vShield Edge."""
-
-    __tablename__ = 'vcns_router_bindings'
-
-    # no ForeignKey to routers.id because for now, a router can be removed
-    # from routers when delete_router is executed, but the binding is only
-    # removed after the Edge is deleted
-    router_id = sa.Column(sa.String(36),
-                          primary_key=True)
-    edge_id = sa.Column(sa.String(16),
-                        nullable=True)
-    lswitch_id = sa.Column(sa.String(36),
-                           nullable=False)
diff --git a/neutron/plugins/vmware/plugin.py b/neutron/plugins/vmware/plugin.py
deleted file mode 100644 (file)
index c841d15..0000000
+++ /dev/null
@@ -1,27 +0,0 @@
-# Copyright 2014 VMware, Inc.
-#
-# All Rights Reserved
-#
-#    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 vmware_nsx.neutron.plugins.vmware.plugins import base as nsx_mh
-from vmware_nsx.neutron.plugins.vmware.plugins import dvs
-from vmware_nsx.neutron.plugins.vmware.plugins import nsx_v
-
-NsxMhPlugin = nsx_mh.NsxPluginV2
-# The 'NsxPlugin' name will be deprecated in Liberty
-# and replaced by the 'NsxMhPlugin' name
-NsxPlugin = NsxMhPlugin
-NsxVPlugin = nsx_v.NsxVPluginV2
-NsxDvsPlugin = dvs.NsxDvsV2
index 165feede54e4a6449a56d20821aa01bf2495ebcd..8235ce3b4f16ac01bce03a6675ed54747dcdfdc4 100644 (file)
--- a/setup.cfg
+++ b/setup.cfg
@@ -121,7 +121,6 @@ neutron.core_plugins =
     nuage = neutron.plugins.nuage.plugin:NuagePlugin
     oneconvergence = neutron.plugins.oneconvergence.plugin:OneConvergencePluginV2
     plumgrid = neutron.plugins.plumgrid.plumgrid_plugin.plumgrid_plugin:NeutronPluginPLUMgridV2
-    vmware = neutron.plugins.vmware.plugin:NsxMhPlugin
 neutron.service_plugins =
     dummy = neutron.tests.unit.dummy_plugin:DummyServicePlugin
     router = neutron.services.l3_router.l3_router_plugin:L3RouterPlugin