neutron/neutron/db/models
Kevin Benton 6dee4c5942 Cleanup _find_related_obj
All of the additional lookup logic was essentially duplicating
a relationship property of 'load_on_pending=True', which tells
SQLAlchemy to lookup the relationship during object creation [1].
So we can dump all of this logic and just use that option.

1. http://docs.sqlalchemy.org/en/latest/orm/relationship_api.html
   #sqlalchemy.orm.relationship.params.load_on_pending

Related: blueprint push-notifications
Change-Id: I0e495a50f5cab9b6449825039d7683d77de1e763
2017-02-25 06:29:33 +00:00
..
plugins Relocate Geneve DB models 2016-09-29 15:48:31 -05:00
README Update README to reflect ML2 Exception in Dir Tree 2016-08-22 15:20:35 +00:00
__init__.py Add devref for Relocating DB models 2016-08-09 15:55:18 +02:00
address_scope.py Use DB field sizes instead of _MAX_LEN constants 2016-12-23 13:48:57 +00:00
agent.py Use DB field sizes instead of _MAX_LEN constants 2016-12-23 13:48:57 +00:00
allowed_address_pair.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
dns.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
dvr.py Relocate dvr model 2016-10-04 08:41:33 +00:00
external_net.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
flavor.py Flavors: move dict extend out of txn 2017-02-15 08:58:35 -08:00
l3.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
l3_attrs.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
l3agent.py Remove deprecation warnings for agents_db 2016-10-13 15:33:22 +00:00
l3ha.py Remove deprecation warnings for agents_db 2016-10-13 15:33:22 +00:00
metering.py Switch to 'subquery' for 1-M relationships 2017-02-06 09:01:31 +00:00
portbinding.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
provisioning_block.py Relocate Provisioning Block DB Model 2016-09-27 04:30:03 +00:00
securitygroup.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
segment.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
servicetype.py Use DB field sizes instead of _MAX_LEN constants 2016-12-23 13:48:57 +00:00
subnet_service_type.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00
tag.py Cleanup _find_related_obj 2017-02-25 06:29:33 +00:00

README

This directory is designed to contain all SQLAlchemy models shipped with core
Neutron.

* The expected directory structure is flat, except for the ML2 plugins. All ML2
  plugin models should fall under the plugins subdirectory (i.e. plugins/ml2/gre_allocation).
* Module names should use singular forms for nouns (port.py, not ports.py).