SSB Architecture

Overview

This page provides a brief overview of the SSB architecture.

Terminology

The following terms are used below:

  • Agent - a client program which sends and receives message.
  • Agent ID - a UUID which identifies an agent.
  • Agent Broker - a component which keeps track of all the agents in the system.
  • Agent Name - a human-readable string which identifies an agent. Agent names don’t necessarily have to be unique. But it would be confusing if they weren’t so the SSB enforces unique agent names.
  • Message Type - a particular type of data. For instance, the gaggle message types include “data matrix,” “network,”, etc.
  • Message Type ID - a URI which uniquely identifies a message type.
  • Translator - object which transforms data from one message type to another.

Components

There are four main components in the SSB:

  • The Agent Broker keeps track of all the registered agents and notifies agents when other agents come and go. The agent broker can also forward messages to agents, although agents generally prefer to communicate directly with each other instead of going through the agent broker.
  • The Name Registry keeps track of the human-friendly names for the registered agents.
  • The Translator Registry keeps track of all the data translators defined.
  • The SSB Boss is a Gaggle Boss implementation which allows geese to connect to the SSB by forwarding messages from geese to agents or the agent broker.

Agent Broker

The agent broker keeps track of all the agents in the system. For each agent, the agent broker stores:

  • The agent’s unique ID.
  • A map from message type ID to the URL to which to send messages of that type.

So an agent which supported some of the gaggle data types might register with a map which looked something like:

Message Type ID Destination
urn:goose.gaggle.ssb.org:data-matrix jms://agent-one/data-matrix
urn:goose.gaggle.ssb.org:name-list jms://agent-one/name-list

An agent which wanted to send a data matrix or name list to this agent would send it to the indicated message queue.

Name Registry

Agents are identified with Universally Unique IDs (UUIDs) which never change and are, as the name indicates, always unique. However, agents also have human-friendly names. The Name Registry keeps track of these names. Its responsibilities include:

  • Keeping track of all the names currently in use.
  • Preventing name clashes. If an agent attempts to use a name already in use by another agent, the name registry will assign a new similar but different name to the new agent.
  • Translating names to IDs. The SSB supports Geese, and Geese use the human-friendly name as the ID. The Name Registry translates these names to UUIDs.
  • Translating IDs to names. When an agent sends a message to a Goose, the Goose wants the agent to be identified by human-friendly name, which the Name Registry provides.

Translator Registry

The translator registry keeps track of all the translators defined in the system. Translators are generally only registered when the server initializes itself, as they don’t usually need to change dynamically.

A translator is a three-tuple which includes:

  • The message type ID of the type to translate from.
  • The message type ID of the type to translate to.
  • An instance of a class which translates data from the source type to the destination type.

SSB Boss

The SSB boss is a simple implementation of the Gaggle boss interface. It accepts messages from geese and forwards them to agents (data messages) or the agent broker (register and unregister).

When a goose registers with the SSB boss, Mule endpoints are automatically created for all of the goose data types. A message sent to one of these endpoints is automatically forwarded to the goose.

 
ssbarchitecture.txt · Last modified: 2009/01/10 03:18 by etellman
 
Recent changes RSS feed Creative Commons License Donate Powered by PHP Valid XHTML 1.0 Valid CSS Driven by DokuWiki