31 Mar 2024 |
b00tr | * This example works fine for me
defmodule Blog.Post do
use Memento.Table,
attributes: [:id, :title, :content, :status, :author_id],
index: [:status, :author_id],
type: :ordered_set,
autoincrement: true
end
Memento.Table.create(Blog.Post)
| 14:48:33 |
shreyan | Nice okay. Now I got the table created, :mnesia.schema also sees it. Writing to the table works fine, but trying to read from it always gives me this error:
** (exit) {:aborted, :no_transaction}
(mnesia 4.23) mnesia.erl:362: :mnesia.abort/1
iex:6: (file)
| 17:15:56 |
shreyan | Oh I just needed to wrap it in a Memento.transaction block, okay. | 17:21:10 |
b00tr | Redacted or Malformed Event | 22:25:38 |
b00tr | Redacted or Malformed Event | 22:25:42 |
b00tr | measured with the benchee:
Name ips average deviation median 99th %
batch_histogram_nif 39.65 K 0.0252 ms ±79.52% 0.0239 ms 0.0441 ms
batch_histogram_elx 0.154 K 6.49 ms ±8.04% 6.39 ms 7.62 ms
Comparison:
batch_histogram_nif 39.65 K
batch_histogram_elx 0.154 K - 257.16x slower +6.46 ms
| 22:30:33 |
b00tr | * measured with the benchee:
Name ips average deviation median 99th %
batch_histogram_nif 0.124 8.04 s ±0.00% 8.04 s 8.04 s
batch_histogram_elx 0.0698 14.33 s ±0.00% 14.33 s 14.33 s
Comparison:
batch_histogram_nif 0.124
batch_histogram_elx 0.0698 - 1.78x slower +6.28 s
| 23:00:39 |
b00tr | yep.. even measured with bash time the difference is about ~1.8x time .. wow .. but the CPU usage is way way lover with NIF | 23:04:18 |
3 Apr 2024 |
| Paul Dann invited Nikolay Tsvetinov. | 08:52:48 |
| Nikolay Tsvetinov joined the room. | 08:54:46 |
| @aniketd:matrix.org left the room. | 10:58:21 |
| skogsbrus changed their profile picture. | 15:36:09 |
4 Apr 2024 |
| @frigidcode:matrix.org left the room. | 17:37:18 |
5 Apr 2024 |
| superherointj changed their display name from superherointj to superherointj 🤑. | 13:45:59 |
| superherointj changed their display name from superherointj 🤑 to superherointj 💥. | 13:47:04 |
| superherointj changed their display name from superherointj 💥 to superherointj 👨💻. | 13:47:32 |
| superherointj changed their display name from superherointj 👨💻 to superherointj 🐴. | 13:48:57 |
6 Apr 2024 |
| superherointj changed their display name from superherointj 🐴 to superherointj. | 15:25:19 |
10 Apr 2024 |
| @thompson_plug:matrix.org joined the room. | 22:38:16 |
12 Apr 2024 |
rkv 🌱 | Apparently a nearly pure Elixir WebRTC stack is being brewed, https://github.com/elixir-webrtc | 04:52:47 |
rkv 🌱 | No RTCDC support though, yet. Hopefully some day... Not sure but very unfortunate if they used OpenSSL for DTLS-SRTP instead of the perfectly good Erlang stack... | 04:53:56 |
| iraklisk joined the room. | 19:16:39 |
14 Apr 2024 |
| syntolog joined the room. | 16:00:39 |
15 Apr 2024 |
| @mortero:matrix.org joined the room. | 23:50:45 |
| @mortero:matrix.org left the room. | 23:50:59 |
16 Apr 2024 |
@thompson_plug:matrix.org | Redacted or Malformed Event | 23:26:28 |
rkv 🌱 | Yo trigger happy Nickel-Cadmium, do what your gun does the best! | 23:56:17 |
17 Apr 2024 |
| Nicd banned @thompson_plug:matrix.org (spam). | 17:13:39 |
Nicd | rkv 🌱: thanks, but remember to ping me next time :) | 17:14:05 |
18 Apr 2024 |
| Robinson D. S. Santos joined the room. | 20:34:26 |