2014-07-08 09:31:05 |
Ann Taraday |
description |
In ml2 models parameter 'default' is used for vnic_type, profile and vif_details, but in migrations 27cc183af192_ml2_vnic_type, 157a5d299379_ml2_binding_profile and 50d5ba354c23_ml2_binding_vif_details is used 'server_default' parameter.
Also MySQL sets server_default parameter for some columns automatically, but this is not mentioned in models and migrations. This is happening for columns:
ml2_gre_endpoints.ip_address
ml2_vxlan_endpoints.ip_address
networkgatewaydevicereferences.interface_name
networkgatewaydevicereferences.network_gateway_id
neutron_nsx_network_mappings.nsx_id
tz_network_bindings.phy_uuid
tz_network_bindings.vlan_id
cisco_credentials.credential_name
cisco_qos_policies.qos_name
cisco_qos_policies.tenant_id
This can be checked as it is shown there http://paste.openstack.org/show/73972/.
This caused differences in models and migrations and MySQL and PostgreSQL usage. |
In ml2 models parameter 'default' is used for vnic_type, profile and vif_details, but in migrations 27cc183af192_ml2_vnic_type, 157a5d299379_ml2_binding_profile and 50d5ba354c23_ml2_binding_vif_details 'server_default' parameter is used. So in database there is default values for this columns http://paste.openstack.org/show/85634/.
Also if in models mentions 'default' it is better to add this into db, as this default could be reached only via code. This situation happened for the following models http://paste.openstack.org/show/85631/ |
|