defmodule MatrixAppService.Migrations do @moduledoc """ Module containing migrations for tables used in bridge mode. Should be used like this: TODO: example """ use Ecto.Migration def change do create table(:users) do add(:local_id, :string) add(:remote_id, :string) add(:data, :map) timestamps() end create(unique_index(:users, [:local_id])) create(unique_index(:users, [:remote_id])) create table(:rooms) do add(:local_id, :string) add(:remote_id, :string) add(:data, :map) timestamps() end create(unique_index(:rooms, [:local_id])) create(unique_index(:rooms, [:remote_id])) end end