Squirrelix.Postgres (Squirrelix v0.2.0)

Copy Markdown View Source

Postgrex-backed query inferrer for Squirrelix inference.

Summary

Functions

Opens a Postgrex connection after a synchronous probe so connection failures and timeouts become structured Squirrelix errors.

Functions

connect(connection_options)

@spec connect(Squirrelix.ConnectionOptions.t()) :: {:ok, pid()} | {:error, struct()}

Opens a Postgrex connection after a synchronous probe so connection failures and timeouts become structured Squirrelix errors.

infer(conn, query)

@spec infer(Postgrex.conn(), Squirrelix.Query.t()) ::
  {:ok, keyword()} | {:error, struct()}

inferrer(conn)