mirror of
https://github.com/ash-project/ash.git
synced 2024-09-20 13:33:20 +12:00
18 lines
359 B
Elixir
18 lines
359 B
Elixir
|
Benchee.run(
|
||
|
%{
|
||
|
"ecto" => fn ->
|
||
|
AshExample.Ticket
|
||
|
|> AshExample.Repo.all()
|
||
|
|> AshExample.Repo.preload(:representative, in_parallel: false)
|
||
|
end,
|
||
|
"ash" => fn ->
|
||
|
:ticket
|
||
|
|> AshExample.Api.query()
|
||
|
|> Ash.Query.side_load(:representative)
|
||
|
|> AshExample.Api.read!()
|
||
|
end
|
||
|
},
|
||
|
time: 10,
|
||
|
memory_time: 2
|
||
|
)
|