LBaaS Refactor HAProxy namespace driver¶
With the new LBaaS object model and driver interface we no longer have a working reference implementation.
Existing HAProxy namespace driver does not implement new LBaaS driver API or support multiple listeners load balancer as supported by new LBaaS object model.
Refactor LBaaS HAProxy namespace driver to use new object model driver interface.
Use Jinja2 to render HAProxy configuration template, rather than the custom configuration generation.
HAProxy configurations may include multiple listeners per load balancer in a single HAProxy process.
Separate files in $state_path/lbaas/$lb_uuid/ placing files written by HAProxy under $state_path/lbaas/$lb_uuid/run to prepare for storing TLS private keys under $state_path/lbaas/$lb_uuid/. Renaming configuration file, PID file and statistics socket stored in $state_path/lbaas/$lb_uuid/ to avoid name conflicts with Stunnel. Further TLS related changes are outside the scope of this spec. The new directory structure will look like this:
$state_path/lbaas/$lb_uuid/ $state_path/lbaas/$lb_uuid/haproxy.conf $state_path/lbaas/$lb_uuid/run/ $state_path/lbaas/$lb_uuid/run/haproxy.pid $state_path/lbaas/$lb_uuid/run/haproxy_stats.sock
The driver will need to detect if the sock and/or PID files are not present in the new locations, and upgrade the running load balancer namespace to this new file system. This will result in a brief interruption of load balancer service while HAProxy is shutdown and configuration updated.
Further TLS and Layer 7 content filtering/manipulation are outside the scope of this spec, but other specs may depend on this.
Data Model Impact¶
REST API Impact¶
Restricting write access to $state_path/lbaas/$lb_uuid/ to root, and placing HAProxy modified files in $state_path/lbaas/$lb_uuid/run/.
Other End User Impact¶
Preformance should remain similar to existing HAProxy namespace driver.
Other Deployer Impact¶
The deployer will need to stop the lbaas-agent before while restarting neutron-server upgrade the database schema and RPC protocol.
The deployer should also note the interruption in load balancer services and each namespace’s file system is updated to the new configuration.
Adding Jinja2 requirement for HAProxy namespace driver functionality, this is already used within Neutron by the VPNaaS driver.
This will significantly affect the HAProxy namespace driver in order to accommodate the new driver interface and multiple listeners.
Addition of Jinja2 requirement for LBaaS support may require DevStack updates.
This change has been in review since Juno. Much discussion has taken place over IRC and the mailing list.
Implement a different LBaaS reference driver.
Develop Jinja2 template for HAProxy configuration.
Update HAProxy namespace driver.
LBaaS API and object model improvements
LBaaS object model driver changes
Implementation of this spec will allow end to end testing of new LBaaS object model.
Existing LBaaS tests should be modified to test LBaaS v2
End-to-end LBaaS v2 tests
Existing LBaaS ref driver documentation needs to be updated.