Comment 3 for bug 1630920

Revision history for this message
Terry Wilson (otherwiseguy) wrote :

The problem is how set_db_attribute is called. The column type of Port.other_config is {'max': 'unlimited', 'value': 'string', 'key': 'string', 'min': 0}, i.e. a dict with string keys and string values. We are passing in an int segmentation_id and a None physical_network. It just happens to work with ovs-vsctl because there is no type since it is all just CLI strings. The fix is when we store things in other_config/external_ids we have to coerce the values to strings to match the column type.

We could try to add some kind of schema inspection to the ovsdb native implementation, but that's a lot of overhead. Really, the OVS Python library itself could try to coerce things to the correct type itself. But its still going to be fastest/best to just pass the right types from the outset.