[openstack-dev] [Quantum][LBaaS] Loadbalancer files organisation

Eugene Nikanorov enikanorov at mirantis.com
Fri May 3 05:11:02 UTC 2013


Hi,

I've filed bug/1175745 to perform the following file tree change in
quantum/lbaas:
1) quantum/db/loadbalancer/loadbalancer_db.py ->
quantum/plugins/services/agent_loadbalancer/loadbalancer_db.py
2) quantum/tests/unit/db/loadbalancer/test_db_loadbalancer.py ->
quantum/tests/unit/services/agent_loadbalancer/test_db_loadbalancer.py
3) quantum/tests/unit/test_loadbalancer_plugin.py ->
quantum/tests/unit/services/agent_loadbalancer/test_loadbalancer_extension.py

__init__.py left in db/loadbalancer and tests/unit/db/loadbalancer/ are
removed.
Loadbalancer extension remains in extensions directory


As a second step, which will be separate bug, I suggest the following name
changes in services:
quantum/plugins/services/agent_loadbalancer ->
 quantum/plugins/services/loadbalancer
and corresponding renaming of unit tests subdir

The intent of this renaming is to show that this implementation is in fact
multivendor.
It's not at this moment, but multivendor support will be implemented using
current plugin, so
I'd also rename agent->agents and driver->drivers.
Under agents I would move current files under namespace_agent subdir.
Under drivers I'd move current files under haproxy_on_host (or something
similar)

All these changes target the following file tree pattern for services:
plugins
  services
     service_type (loadbalancer, fw)
        agents
            vendor_specific_agent (vendor or implementation-specific)
        drivers
            vendor_specific_agent
        this_service_type_db_plugin.py
        alt_service_type_implementation
            whatever (including possible alternative DB plugin)

I'd suggest the same pattern for the unit tests.

Thanks,
Eugene.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.openstack.org/pipermail/openstack-dev/attachments/20130503/796babe8/attachment.html>


More information about the OpenStack-dev mailing list