Hive server

The hive serves as the central hub where bees connect and communicate with one another

The Hive is the central server that acts as a mediator between the bee agents, enabling communication and routing messages between them. Each bee's configured routes inform the Hive on how to direct messages. The Hive maintains the configuration of all connected bees, automatically synchronizing any modifications, allowing the bees to adapt to new requirements.

Hive messaging and settings flow

The Hive can be managed through its API, accessible using the beectl command line tool. The API can also be utilized to integrate third-party applications or services for managing the Hive and controlling the settings of connected bees.

Hive general overview

Store backends

Data can be stored in different types of SQL databases, such as SQLite by default in standalone mode, or in external database engines such as MySQL or PostgreSQL for cluster-type configurations, where the data resides on an external server. Additionally, data can be stored in a distributed key-value store such as Etcd. Hive includes a built-in Etcd server module that can be activated via settings and used in both standalone and cluster modes.

The modules embedded in Hive, such as the Etcd server, can be activated from the Hive's startup settings. However, to optimize resources in Hive, it is possible to obtain a version of Hive without the integrated Etcd module, resulting in a smaller executable that consumes fewer resources

Hubs

The bee agents connect to the hive through hubs, which serve as a sandbox inside the hive. Bees connected to one hub cannot communicate with bees connected to another hub, thus allowing for isolated messaging and connectivity permissions.

A hive server can have one or more hubs and can be configured to have as many as necessary.

Hive hub connectivity

The connection of a bee to the hub is established through roles, which determine the topics the bee can publish or subscribe to.

Topics

Topics are simple names, made up of a string of characters, that serve as a means for publishers and subscribers to find each other. They connect messages from one bee to another. A bee agent publishes messages to a specific topic, and other bees that are interested in that topic subscribe to receive the messages.

Topics routing

Topics are configured in the routes of the bees, along with their network pattern. This information allows the hive server to determine whether to use publish/subscribe patterns or expose services on topics that require a response.

Topics can be shared between different hubs, which enables two bee agents to communicate messages for a specific topic and exchange streams between hubs.

Bee monitoring

The hive server is not only responsible for configuring bees and routing messages, but it also monitors the connectivity of each bee. The hive gathers all the logs generated by the bees and provides the option to store or view them in real-time through the log stream.

Hive mesh

The hive server can be connected to other hives, forming a network of interconnected hives, known as the hive mesh. This topology allows for transmitting bee messages between different hive servers.

Hive mesh

Message sharing can occur between hubs within the same hive or between hubs of different hives, enabling local transmission of messages within the hive or extending the reach of certain topics to bees connected to different hives.

Communication between bees from different hives

Hive clustering

Last updated