stratos-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Imesh Gunaratne <>
Subject Load Balancer Extension API & HAProxy Reference Implementation
Date Wed, 13 Nov 2013 06:32:20 GMT

This is a brief introduction to Load Balancer Extension API and its
reference implementation for HAProxy.

The following figure illustrates the Load Balancer Interface which needs to
be implemented for a given load balancer to manage its life-cycle. Please
refer the method comments for details:

[image: Inline image 2]

HAProxy implementation of the above interface could be found at:;a=blob;f=extensions/load-balancer/haproxy-extension/src/main/java/org/apache/stratos/haproxy/extension/;h=cdb8bd36a0ab151b0239d86ccefbc77804777eb8;hb=HEAD

The following class: LoadBalancerExtension has been used to execute the
life-cycle of the load balancer.

1. Wait for the complete topology event. This will initialize the local
topology data structure once the event is received.
2. Configure and start the load balancer: Invokes LoadBalancer.configure()
and LoadBalancer.start()
3. Listen to Topology Update Events which update load balancer
4. Once an event is received, reload load balancer configuration: Invokes
5. When the extension is stopped LoadBalancer.stop() will be invoked.

[image: Inline image 1]


View raw message