Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.jboss.ha.framework.interfaces
Class RoundRobin

    java.lang.Object
      org.jboss.ha.framework.interfaces.RoundRobin

All Implemented Interfaces:
  LoadBalancePolicy, Serializable

public class RoundRobin
extends Object
implements LoadBalancePolicy

LoadBalancingPolicy implementation that always favor the next available target load balancing always occurs.

Version:
  $Revision: 1.6 $
Author:
  Sacha Labourey., Bill Burke.
See Also:
  `LoadBalancePolicy`, Serialized Form

Constructor Summary
`RoundRobin()`

Method Summary
`Object` | `chooseTarget(FamilyClusterInfo clusterFamily)` Called when the stub wishes to know on which node the next invocation must be performed.
`Object` | `chooseTarget(FamilyClusterInfo clusterFamily, org.jboss.invocation.Invocation routingDecision)` Called when the stub wishes to know on which node the next invocation must be performed.
`void` | `init(HARMIClient father)` Initialize the policy with a reference to its parent stub.

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Constructor Detail

### RoundRobin

    public RoundRobin()

Method Detail

### init

    public void init(HARMIClient father)

  Description copied from interface: `LoadBalancePolicy`
  Initialize the policy with a reference to its parent stub. the load-balancing policy implementation can use HARMIClient data to take its decision

  Specified by:
    `init` in interface `LoadBalancePolicy`
  Parameters:
    `father` - The stub that owns the policy

### chooseTarget

    public Object chooseTarget(FamilyClusterInfo clusterFamily)

  Description copied from interface: `LoadBalancePolicy`
  Called when the stub wishes to know on which node the next invocation must be performed.

  Specified by:
    `chooseTarget` in interface `LoadBalancePolicy`
  Parameters:
    `clusterFamily` - A list of potential target nodes
  Returns:
    The selected target for the next invocation

### chooseTarget

    public Object chooseTarget(FamilyClusterInfo clusterFamily,
                               org.jboss.invocation.Invocation routingDecision)

  Description copied from interface: `LoadBalancePolicy`
  Called when the stub wishes to know on which node the next invocation must be performed.

  Specified by:
    `chooseTarget` in interface `LoadBalancePolicy`
  Parameters:
    `clusterFamily` - A list of potential target nodes
    `routingDecision` - The actual invocation object if the policy wants to have some kind of invocation-based routing strategy
  Returns:
    The selected target for the next invocation

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Copyright © 2002 JBoss Group, LLC. All Rights Reserved.