Agent Deployer Developer Guide

Overview

The Agent Deployer is a back-end component that enables the customization of a new agent to be added in the EFPF Online Bidding Process ecosystem. This component provides the following features:

  • exposes APIs to retrieve the configuration options from the UI
  • builds a Docker image based on the configuration provided
  • deploys and runs a Docker container in the Agent Pool
  • provides access to the new deployed agent to the UI

The Agent Deployer could be exploited by the UI from the EFPF Portal.


Design and Architecture

The Agent Deployer is written in Python and exploits an open source library to handle the Docker environment that runs on the server machine.

The Agent Deployer exposes a RESTful web service to enable communications with the User Interface that provides configuration and the forms to create a new agent in the ecosystem.

The Agent Deployer maintains an Agent Pool where it deploys all the EFPF agents behind a Nginx proxy server to provide easy access to the UI to control the agent over its own APIs.

Figure 1. UI-Agent Deployer-Agent Pool communication

The figure shows the interconnection between the UI and the Agent Deployer:

  • the UI asks for the creation of a new agent
  • the Agent Deployer builds the agent
  • the Agent Deployer provides info to the UI about the endpoint of the new agent

The figure shows the interconnection between the Agent Deployer and the Agent Pool:

  • the Agent Deployer deploys the new agent in the Agent Pool

The figure shows the interconnection between the UI and the Agent Pool:

  • the UI interacts with a specific agent behind the proxy (thanks to endpoint info collected at creation time)
  • the UI sends interaction command by exploiting agent’s APIs and get back a response

It is possible to look at what is happening to an agent and in which bidding processes the agent is involved in through the EFPF Bidding Process UI after the user who owns the agent has been authenticated by the EFPF Security framework.


Components

The table below contains the technology used for the development of each Agent Deployer architecture component.

Component Technology
Agent Deployer Python - Docker Py SDK
Agent Pool Docker - Nginx
Database mySQL

Next