An Ecto libSQL Adapter. Uses ExLibSQL as the driver to communicate with libSQL. Based on the Ecto SQLite3 Adapter
defp deps do
[
{:ecto_libsql, "~> 0.1"}
]
endDefine your repo similar to this.
defmodule MyApp.Repo do
use Ecto.Repo, otp_app: :my_app, adapter: Ecto.Adapters.LibSQL
endConfigure your repository similar to the following. If you want to know more
about the possible options to pass the repository, checkout the documentation
for Ecto.Adapters.LibSQL. It will have
more information on what is configurable.
config :my_app,
ecto_repos: [MyApp.Repo]
config :my_app, MyApp.Repo,
mode: :local,
path: "path/to/my/database.db"We have some benchmarks comparing it against the MySQL and Postgres adapters.
You can read more about those at bench/README.md.
Running unit tests
mix testRunning integration tests
EX_LIBSQL_INTEGRATION=true mix test