Ferricstore.Migration.RedisCompatibility (ferricstore v0.7.3)

Copy Markdown View Source

Redis migration compatibility matrix and workload assessment helpers.

The matrix is built from FerricStore command metadata first, then from native parser metadata for implemented commands that do not yet have full Redis-style COMMAND metadata. Curated entries are used for important Redis commands that FerricStore intentionally does not support.

Summary

Functions

Assesses command usage lines from MONITOR logs, commandstats, or simple command-per-line traces.

Returns the Redis migration compatibility matrix.

Renders an assessment report as :markdown or :json.

Renders the compatibility matrix as :markdown or :json.

Types

matrix_entry()

@type matrix_entry() :: %{
  command: binary(),
  status: status(),
  source: source(),
  arity: integer() | nil,
  flags: [binary()],
  first_key: integer() | nil,
  last_key: integer() | nil,
  step: integer() | nil,
  summary: binary(),
  notes: binary(),
  alternative: binary()
}

source()

@type source() :: :catalog | :native_ast_parser | :migration_catalog

status()

@type status() ::
  :compatible
  | :different
  | :partial
  | :unsupported
  | :ferricstore_extension
  | :unknown

Functions

assess_lines(lines)

@spec assess_lines(Enumerable.t()) :: map()

Assesses command usage lines from MONITOR logs, commandstats, or simple command-per-line traces.

matrix()

@spec matrix() :: [matrix_entry()]

Returns the Redis migration compatibility matrix.

render_assessment(report, atom)

@spec render_assessment(map(), :markdown | :json) :: binary()

Renders an assessment report as :markdown or :json.

render_matrix(atom)

@spec render_matrix(:markdown | :json) :: binary()

Renders the compatibility matrix as :markdown or :json.