howdy/flags/database

Flag settings kept in a Gloo Repo, on PostgreSQL or SQLite, through howdy/database. Every node reading the same database shares them.

import howdy/flags
import howdy/flags/database as flags_database

let assert Ok(Nil) = migration.run(db, [flags_database.schema()])
let assert Ok(store) = flags_database.store(db)
let assert Ok(features) =
  flags.new(store) |> flags.register(my_app.all_flags()) |> flags.start

Values

pub fn schema() -> migration.Package

The howdy_flags_ tables. Run with howdy/migration during deployment.

pub fn store(
  repo: repo.Repo,
) -> Result(flags.Store, service.Error)

A store over this Repo, once its schema is checked: the flags refuse to start on a database that has not been migrated.

✨ Search Document