Hi Hugo,

I was really interested to read this thread and to see your work on the
OvsVifDriver.

I've been looking at the VIF driver part of the KVM code and had a few
questions:

1. What do you think of the idea of allowing different VIF drivers per
traffic type?

>From reading commits, it looks like in the OCS case, all traffic
(Management, Control, Storage traffic for System VMs as well as Guest and
Public traffic from Guest VMs) will run over OVS.

I think some plugins (e.g. the MidoNet plugin) will want to run only Guest
/ Public traffic over the virtual network, and leave Storage / Management /
Control traffic, which are relevant only for System VMs, to run over the
physical network (using BridgeVifDriver).

The LibVirtComputingResource code currently assumes that there is exactly
one VIF driver, which essentially forces plugins to run all traffic in the
same way.

I think ideally we would want to be able to specify the VIF driver on a
per-traffic-type basis.

Currently, in agent.properties, we have one line like this:
libvirt.vif.driver=com.cloud.network.resource.BridgeVifDriver

I was thinking that we could allow optional per-traffic-type overrides,
something like this:
libvirt.vif.driver.Guest=com.cloud.network.resource.OvsVifDriver

The above would mean that Guest traffic only would use the OvsVifDriver,
while all other traffic would use the default driver.

What do you think of that idea? From the current implementation of
OvsVifDriver, it looks like the idea of traffic separation may not be
relevant to your plugin, but I'd be interested to get your take.

2. Is there any way to avoid the code duplication between BridgeVifDriver
and OvsVifDriver?

I'm not sure exactly what the solution is here, but I noticed that the two
classes are the same apart from some small changes. So (for example) if the
default bridge names, timeouts, control network behaviour etc changed in
BridgeVifDriver, OvsVifDriver would need to change at the same time, or
become out of sync. One approach might be to have a base BridgeVifDriver
which provides bridge VIF behaviour but doesn't define how it's
implemented, and extend it with LinuxBridgeVifDriver and OvsBridgeVifDriver
each overriding where necessary, e.g. specifying how to create a bridge and
check if a bridge exists.

Interested to hear your thoughts, and looking forward to more discussion as
we start working in earnest on the MidoNet networking plugin.

Thanks,
Dave.

Reply via email to