Skip to content
This repository has been archived by the owner on Jul 10, 2024. It is now read-only.

DispatchStrategies

Philipp Haussleiter edited this page Nov 25, 2015 · 1 revision

Dispatch Strategies

Since Version 0.5.0 Bundle-Bee provides a set of three very basic dispatching strategies. These strategies are very simplistic at the moment, but they demonstrating the implementation of a dispatching strategy within the Bundle-Bee Framweork.
You can switch between these strategies by changing the value of the org.bundlebee.weaver.servicecalldispatchstrategy Property in the plugins/config.ini file, before you startup the BB-Runtime.
The Strategies are used to call a defined Node-Manager within you grid to startup a service. The Node is estimated by applying the Strategy to all Nodes in the grid.
A short description of the three strategies:

org.bundlebee.weaver.RoundRobinDispatchStrategy

This is an attempt to use a Round-robin_scheduling. Every time another node will be selected. The Service will also be deployed, installed and started at the remote node, if this is necessary.

org.bundlebee.weaver.BundleStateDispatchStrategy

This Strategy aims to use first all nodes, that are most capable to run the needed service:

  1. Search for a node, with the needed service already installed.
    if there is no such node…
  2. Search for a node, with the needed service deployed (stored in the node’s Repository). Then install the service.
    if there is no such node…
  3. Search for another node (and deploy & install the service there)

org.bundlebee.weaver.RandomDispatchStrategy

This Strategy just chooses from a list of all active nodes one at random. (the service will be deploy & installed if necessary)