com.alibaba.druid.pool.ha.balance
Class LeastConnectionBalancer

java.lang.Object
  extended by com.alibaba.druid.pool.ha.balance.AbstractBalancer
      extended by com.alibaba.druid.pool.ha.balance.LeastConnectionBalancer
All Implemented Interfaces:
Balancer

public class LeastConnectionBalancer
extends AbstractBalancer


Constructor Summary
LeastConnectionBalancer()
           
 
Method Summary
 void afterDataSourceChanged(DataSourceChangedEvent event)
           
 MultiConnectionHolder getConnection(MultiDataSourceConnection conn, String sql)
           
 
Methods inherited from class com.alibaba.druid.pool.ha.balance.AbstractBalancer
getMultiDataSource, init, isInited
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

LeastConnectionBalancer

public LeastConnectionBalancer()
Method Detail

afterDataSourceChanged

public void afterDataSourceChanged(DataSourceChangedEvent event)

getConnection

public MultiConnectionHolder getConnection(MultiDataSourceConnection conn,
                                           String sql)
                                    throws SQLException
Throws:
SQLException


Copyright © 2012 Alibaba Group. All Rights Reserved.