minos.common.configuration.config module

minos.common.configuration.config.BROKER

alias of minos.common.configuration.config.Broker

minos.common.configuration.config.DISCOVERY

alias of minos.common.configuration.config.Discovery

class minos.common.configuration.config.MinosConfig(path, with_environment=True, **kwargs)[source]

Bases: minos.common.configuration.config.MinosConfigAbstract

A Minos configuration provides information on the connection points available at that service. It consists of the following parts:

  • Service meta-information (such as name, or version).

  • REST Service endpoints available.

  • Repository database connection for event sourcing.

  • Snapshot database connection.

  • Events it publishes/consumes from de given Kafka service.

  • Commands it reacts to from other microservices.

  • Sagas it takes part on.

__init__(path, with_environment=True, **kwargs)[source]
property broker: minos.common.configuration.config.Broker

Get the events config.

Return type

minos.common.configuration.config.Broker

Returns

A EVENTS NamedTuple instance.

property discovery: minos.common.configuration.config.Discovery

Get the sagas config.

Return type

minos.common.configuration.config.Discovery

Returns

A DISCOVERY NamedTuple instance.

property middleware: list

Get the commands config.

Return type

list[str]

Returns

A list containing the service class names as string values..

property repository: minos.common.configuration.config.Repository

Get the repository config.

Return type

minos.common.configuration.config.Repository

Returns

A REPOSITORY NamedTuple instance.

property rest: minos.common.configuration.config.Rest

Get the rest config.

Return type

minos.common.configuration.config.Rest

Returns

A REST NamedTuple instance.

property saga: minos.common.configuration.config.Saga

Get the sagas config.

Return type

minos.common.configuration.config.Saga

Returns

A SAGAS NamedTuple instance.

property service: minos.common.configuration.config.Service

Get the service config.

Return type

minos.common.configuration.config.Service

Returns

A SERVICE NamedTuple instance.

property services: list

Get the commands config.

Return type

list[str]

Returns

A list containing the service class names as string values..

property snapshot: minos.common.configuration.config.Snapshot

Get the snapshot config.

Return type

minos.common.configuration.config.Snapshot

Returns

A SNAPSHOT NamedTuple instance.

class minos.common.configuration.config.MinosConfigAbstract(path)[source]

Bases: abc.ABC

Minos abstract config class.

__init__(path)[source]
minos.common.configuration.config.QUEUE

alias of minos.common.configuration.config.Queue

minos.common.configuration.config.REPOSITORY

alias of minos.common.configuration.config.Repository

minos.common.configuration.config.REST

alias of minos.common.configuration.config.Rest

minos.common.configuration.config.SAGA

alias of minos.common.configuration.config.Saga

minos.common.configuration.config.SERVICE

alias of minos.common.configuration.config.Service

minos.common.configuration.config.SNAPSHOT

alias of minos.common.configuration.config.Snapshot

minos.common.configuration.config.STORAGE

alias of minos.common.configuration.config.Storage