types/service

Service shape — all fixed-branch services conform to this. The supervised flag declares whether this service needs OTP supervision.

Types

pub type Service {
  Service(
    name: String,
    supervised: Bool,
    start: fn() -> Result(Nil, String),
    stop: fn() -> Nil,
    health: fn() -> Bool,
  )
}

Constructors

  • Service(
      name: String,
      supervised: Bool,
      start: fn() -> Result(Nil, String),
      stop: fn() -> Nil,
      health: fn() -> Bool,
    )
Search Document