Skip to content

Design st2::profile::server split

Ankur Singh edited this page Sep 15, 2021 · 9 revisions

This is a design document for splitting up st2::profile::server

Goals:

  • Split up st2::profile::server into individual services
  • Would like each service to be independent so that they can be installed/configured/managed individually
    • This is ideal for HA deployments / scaling where we might want only a select few services on a host, and maybe no MongoDB, etc.
  • To follow the pattern setup by other common/popular modules, move st2::profile::* into st2::server::* or other appropriate places

Design:

  • There should be a top level st2::server class that can be an over-arching install of a "server" and its components (preferably selectable using variables)
  • Each service would have its own class, example st2::server::actionrunner, st2::server::mongodb
  • Configs should have their own classes, because many of the services share common configs like [db]
  • Configs should live in its own directory st2::server::config (st2/server/config
  • Each config section should have its own config class st2::server::config::db, st2::server::config::actionrunner, etc

Services:

  • st2actionrunner
  • st2api
  • st2auth
  • st2chatops
    • nodejs
  • st2garbagecollector
  • st2notifier
  • st2rulesengine
  • st2scheduler
  • st2sensorcontainer
  • st2stream
  • st2timersengine
  • st2workflowengine
  • st2web
    • nginx
  • RabbitMQ (common, but should be able to be setup on one node and not others)
  • MongoDB (common, but should be able to be setup on one node and not others)
  • Redis (common, but should be able to be setup on one node and not others)

Config Sections:

Common

  • system
  • coordination
  • database
  • messaging

Endpoint services

  • api
  • auth
  • stream
  • webui

System settings?

  • system_user
  • syslog
  • log
  • ssh_runner
  • keyvalue

Services

  • actionrunner

  • garbagecollector

  • notifier

  • rulesengine

  • scheduler

  • sensorcontainer

  • timersengine

  • workflow_engine

  • resultstracker ?

  • exporter ?

Service -> Config Section mapping:

Common

  • system
  • coordination
  • database
  • messaging

System settings? Common?

  • system_user
  • syslog
  • log
  • ssh_runner (only actionrunner?)
  • keyvalue

Endpoint services, needed 1->1 for the services when running, but some settings needed by others (URLs?)

  • api
  • auth
  • stream
  • webui

Services 1 -> 1 config

  • actionrunner
  • garbagecollector
  • notifier
  • rulesengine
  • scheduler
  • sensorcontainer
  • timersengine
  • workflow_engine