bgoosman
I got a very basic NIF working for KuzuDB: GitHub - bgoosmanviz/kuzu_nif: Adapting KuzuDB's Rust crate to Elixir using Rustler · GitHub.
KuzuDB is an embedded graph database, in the same sense sqlite is an embedded sql database.
Posting here in case anyone is interested in helping flesh it out. I don’t know Rust very well.
Trending in Questions
I’m working on a project that simulates the bumbl example in the programming phoenix book. It acts almost like an email client. We have a...
New
Hello,
I know there is an approach for handling lists that allows for optimized traversal, but I can’t recall the specific method (somet...
New
I’m seeing that a list inside a Kino.DataTable will be interpreted as a charlist, even if the Kino.configure() is set to charlists: :as_l...
New
So my question is quite simple and i have found no conclusive answer on forum, google or AI.
Should we use :erlang.float for Integer to ...
New
Hi, I’ve just set up an application with ash_authentication. There is only magic link strategy for now, so there is no confirmation add o...
New
Documentation
While reading the Scoped Routes section, I noticed that the documentation currently refers to a problem without explainin...
New
If a change or preparation module uses Ash.Changeset.get_argument/2 or Ash.Query.get_argument/2 (or any of the other get_argument functio...
New
Other Trending Topics
I am happy to introduce the very α version of the new programming language compiled to BEAM.
Welcome Cure.
It has literally three kille...
New
Hi there! We created Gust: A task orchestrator inspired by Airflow.
For those who have never heard about Aiflow, it’s a Python-based wor...
New
Beam Bots (or just BB for short) is a framework for building fault-tolerant robotics applications in Elixir using familiar OTP patterns. ...
New
Xamal is a deployment tool for Elixir apps that deploys native releases to bare metal servers over SSH. It’s a port of GitHub - basecamp/...
New
Corex is an accessible, unstyled UI component library for Phoenix that integrates Zag.js state machines using Vanilla JavaScript and Live...
New
With AI doing more of the implementation work, I’ve been wondering how much coding I should deliberately keep doing myself.
My main conc...
New
Categories:
Sub Categories:
Forums
Popular Tags
- #ecto
- #liveview
- #troubleshooting
- #learning-elixir
- #library
- #deployment
- #erlang
- #testing
- #genserver
- #mix
- #absinthe
- #remote-other
- #otp
- #plug
- #how-to-question
- #macros
- #postgres
- #elixirconf
- #channels
- #exunit
- #discussion
- #code-sync
- #podcasts
- #javascript
- #onsite
- #dialyzer
- #docker
- #authentication
- #umbrella
- #full-time-contract
- #podcasts-by-brainlid
- #ecto-query
- #ai
- #elixirconf-us
- #blog-post
- #elixir-ls
- #phoenix_html
- #iex
- #graphql
- #genstage
- #websockets
- #supervisor
- #advent-of-code
- #distillery
- #processes
- #api
- #forms
- #hex
- #security
- #metaprogramming










Showing Posts 1 to 10- Show Best Posts
- Show All (oldest first)
- Show All (newest first)
iampeter
Hi, great job with starting the project, @bgoosman
I’m wondering what your plans are in regard to the repo’s future; thanks!
bgoosman
I think integrating it with the Explorer library would be nice. i.e. pass dataframes from Elixir to/from the NIF, to be loaded into kuzudb, or fetched from kuzudb. I tried without much success.
WDYT?
bgoosman
Thanks for reminding me about this. I just updated the kuzu crate from 0.6.0 to 0.7.0 and improved the Elixir unit test.
We can do some pretty useful things with just run_query, like create a kuzudb using COPY FROM commands.
bgoosman
Besides that, feature parity with the API.
iampeter
Thanks for updating your repo @bgoosman . Yes passing dataframes would be a good idea.
I’m wondering how the BEAM process management maps onto Rust threads, i.e. can we achieve proper query concurrency using KuzuDB via Elixir?
Are you using KuzuDB in production with your integration? What is the use case, without getting into any trade secrets
bgoosman
Not sure about BEAM & Rust threads. Here’s KuzuDB’s concurrency model https://docs.kuzudb.com/concurrency.
You got me thinking about the connection to the db. Right now run_query will create a new connection every time it’s called, which doesn’t sound ideal. I wonder how to manage a persistent connection.
bgoosman
We’re a graph viz company, so having an embeddable graph engine like KuzuDB would be an excellent improvement over a server based graph engine like Neo4j.
iampeter
That’s my goal as well - being able to do in-mem Cypher queries.
iampeter
Maybe @filmor @hansihe or @evnu could point us in the right direction in terms of how the mapping between BEAM processes and threads in Rust works.
ruslandoga
I was curious so I took a peek, and I think this function might benefit from being scheduled on a dirty scheduler: kuzu_nif/native/kuzu_ex/src/lib.rs at f94c2e243983650db26c4b19bb0f73835fd52ec5 · bgoosmanviz/kuzu_nif · GitHub and re: “mapping processes to threads”, I think usually libraries for wrappers around embedded databases create a NIF resource per database connection and then Elixir / Erlang manage them however they want, no 3rd-party threads involved. Looking at kuzu_nif/native/kuzu_ex/src/lib.rs at f94c2e243983650db26c4b19bb0f73835fd52ec5 · bgoosmanviz/kuzu_nif · GitHub, it seems like the API might be similar to DuckDB wrappers, since they also have a notion of “databases” and “connections” (SQLite only has “databases”). Two example DuckDB wrappers in Elixir:
So I think the API could be:
I think this would be useful in the upcoming AoC