Skip to main content

BOSS Object Starter Service (BOSS)

BOSS is a service that instantiates Python objects as HEROs based on a JSON configuration. The configuration can be read from a file, a URL (e.g. from a CouchDB), or from an environment variable. Essentially, BOSS allows you to quickly wrap your arbitrary Python object as a HERO and to run it.

📖 Below is a quick walkthrough of the basic functionalities. You find the full documentation here.

As an example, let's take an object available in the Python standard library, the FTP class from the ftplib module. To make BOSS create an object of the class FTP, we need the following configuration:

{
     "_id": "test-json-ftp",
     "classname": "ftplib.FTP",
     "arguments": {
          "host": "ftp.us.debian.org"
     }
}
python -m boss.starter -u file:///absolute/path/to/ftp.json

Now our object is available in the default realm of our HEROS network. It can be viewed with any HEROObserver. For a graphical view, use HERO-Monitor.

Exposing the BOSS instance itself

To expose the BOSS instance as a HERO, use the --expose command line flag:

python -m boss.starter --expose -u file:///absolute/path/to/ftp.json

When the BOSS instance is exposed, HEROs can be dynamically added and removed by the calling the add_hero(config: dict) and remove_hero(name: str) methods. This allows to run BOSS without any initial configuration and manage the running HEROs from a remote service.

By default, the instance receives a unique name consisting of the hostname and a UUID. To change the name, use the --name argument:

python -m boss.starter --expose --name my_test_boss -u file:///absolute/path/to/ftp.json

Using the asyncio main loop

BOSS starts a asyncio loop that the started objects can use. If your object expects to get the loop object in the constructor you can define attach it to the boss loop through the magic string "@_boss_loop" as in the following example:

{
  "_id": "statemachine",
  "classname": "herostools.actor.statemachine.HERODatasourceStateMachine",
  "arguments": {
    "loop": "@_boss_loop",
    "http_port": 9090,
    "bind_address": "localhost",
    "labels": {"system": "heros"}
  }
}

Docker

A convenient way to deploy BOSS is inside of a Docker container. You can find pre-built containers images in our Docker registry.

You can also build the BOSS Docker image yourself from the Dockerfile in the repository:

docker build -t atomiq/boss .

A BOSS Docker service can be started with the following compose file

version: '2'

services:
  httpclient:
    image: registry.gitlab.com/atomiq-project/boss:latest
    restart: always
    network_mode: host
    environment:
     - |
       BOSS1=
       {
        "_id": "docker-env-ftp",
           "classname": "ftplib.FTP",
           "arguments": {
                "host": "ftp.us.debian.org"
           }
       }
    command: python -m boss.starter -e BOSS1

Additionally, also specifying a file or URL is possible, such that (mounted) JSON files in the Docker container or web URLs can be used as configuration sources. Note that the -e and -u options can be specified multiple times to define several objects that should be instantiated by the BOSS.

Metadata

Release files for heros-boss 2026.0.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for heros-boss 2026.0.4
File Size Uploaded Provenance Actions
heros_boss-2026.0.4.tar.gz 294.9 kB Without provenance Details for heros_boss-2026.0.4.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for heros-boss 2026.0.4
File Interpreter ABI Platform Actions
heros_boss-2026.0.4-py3-none-any.whl Python 3 none any Details for heros_boss-2026.0.4-py3-none-any.whl

Total release size: 318.2 kB

Release files / heros_boss-2026.0.4.tar.gz

Download URL heros_boss-2026.0.4.tar.gz
Size 294.9 kB
Tags Source
SHA-256 checksum
How to use checksums
8d6386d1fda7f2b0cb740216bf3c03fc324c4ebd03ad6d1c5ca0e0dc5985e879
BLAKE2b-256 checksum
How to use checksums
258352eca159bda76c08d1b16b855d2584cf1ec0e1b7acd8927edb70f1a0ea21
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.9

Release files / heros_boss-2026.0.4-py3-none-any.whl

Download URL heros_boss-2026.0.4-py3-none-any.whl
Size 23.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
845b57360cc4f96b12a2852fe618d70e002c8c5732ff327dc0d212ea8c9ed18b
BLAKE2b-256 checksum
How to use checksums
b6bd7b14d150d51339e4367dda1bddc2c253b678123db649dd4009a75dca77bc
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.14.9

Security for heros-boss 2026.0.4

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

2026.0.4 This release

2 release files No provenance

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page