Commit graph

39 commits

Author SHA1 Message Date
Pekka Enberg
47e08d34bf bindings/rust: Fix Rows::next() I/O dispatcher handling
The `next()` function needs to be a loop to make sure we actually return rows.
2025-06-16 14:28:08 +03:00
Pekka Enberg
90c1e3fc06 Switch Connection to use Arc instead of Rc
Connection needs to be Arc so that bindings can wrap it with `Mutex` for
multi-threading.
2025-06-16 10:43:19 +03:00
Jussi Saurio
b5ac095716 Fix off-by-one error in max_frame after WAL load 2025-05-25 19:34:51 +03:00
Jussi Saurio
6254246541 use tempfile in test 2025-05-25 10:25:52 +03:00
Jussi Saurio
208639c5ee clippy 2025-05-24 21:01:13 +03:00
Jussi Saurio
67359dc17b Add another persistence test and also assert that the data was in the WAL, not the main db 2025-05-24 20:44:47 +03:00
Jussi Saurio
1baa9c7038 Add regression test for being able to read WAL from disk 2025-05-24 18:35:53 +03:00
Diego Reis
4766c9c286 bind/rust: Fix lifetime issue with pragma_query
Shallow cloning in Row ended up invalidating the pointer
to value
2025-05-19 21:29:07 -03:00
Diego Reis
ed0e3b1ba2 bind/rust: Implement pragma_query 2025-05-19 14:04:59 -03:00
Diego Reis
72a1cd5e3c wip: pragma_query method 2025-05-18 17:39:22 -03:00
Pekka Enberg
e3f71259d8 Rename OwnedValue -> Value
We have not had enough merge conflicts for a while so let's do a
tree-wide rename.
2025-05-15 09:59:46 +03:00
Jussi Saurio
e57cea8de7 Merge 'reset statement before executing in rust binding' from Pedro Muniz
Closes #1426

Closes #1436
2025-05-03 18:34:44 +03:00
pedrocarlo
7cc190a12b reset statement before executing 2025-05-02 19:26:44 -03:00
Peter Hayman
8f366e98d5 add Row::column_count 2025-05-01 15:31:38 +10:00
Peter Hayman
29d463aa89 implement Clone for Arc<Mutex> types 2025-04-28 00:22:39 +10:00
Timo Kösters
1c82752473
feat: Statement::columns function for Rust bindings 2025-04-21 13:17:50 +02:00
Pekka Enberg
207563208f stress: Add support for INSERT, DELETE, and UPDATE 2025-04-10 11:59:25 +03:00
tsar-boomba
89c0b0b862 Implement Clone and Debug for rust binding's Database 2025-04-02 18:22:57 -07:00
Pere Diaz Bou
ee55116ca6 return row as reference to registers 2025-03-29 22:04:08 +01:00
Pere Diaz Bou
bf37fd3314 wip 2025-03-29 22:02:49 +01:00
Pere Diaz Bou
9291f60722 Introduce Register struct
OwnedValue has become a powerhouse of madness, mainly because I decided
to do it like that when I first introduced AggContext. I decided it was
enough and I introduced a `Register` struct that contains `OwnedValue`,
`Record` and `Aggregation`, this way we don't use `OwnedValue` for
everything make everyone's life harder.

This is the next step towards making ImmutableRecords the default
because I want to remove unnecessary allocations. Right now we clone
OwnedValues when we generate a record more than needed.
2025-03-27 17:53:02 +01:00
Yirt Grek
bb68fbdd67 bindings/rust: Fix bindings so example runs 2025-03-12 00:54:18 -07:00
Pekka Enberg
96175cccf7 cli: Add --experimental-mvcc option to enable MVCC 2025-03-06 10:16:42 +02:00
Pere Diaz Bou
8daf7666d1 Make database Sync + Send 2025-03-05 14:07:48 +01:00
南宫茜
71921ee178
Enable local file connection in Rust binding
It's so weird that other bindings can open local file but Rust binding itself cannot.
2025-03-05 17:38:23 +08:00
Pekka Enberg
50f9cc449c bindings/rust: Fix complaints about non-Sync/Send use of Arc
We probably should drop the `Rc` from `Connection` in the core, but
let's paper over it for now.
2025-02-27 10:43:58 +02:00
Pekka Enberg
08c1dce549 bindings/rust: Improve API support
Add support for Statement::query() and others to wire up more of Limbo
core to the Rust bindings.
2025-02-27 10:38:16 +02:00
Pekka Enberg
98e3bc0c0c bindings/rust: Make library thread-safe 2025-02-27 10:22:22 +02:00
Pekka Enberg
f0b29167cd bindings/rust: Fix Database::connect() signature
We don't want to consume `self`...
2025-02-27 10:10:51 +02:00
Pekka Enberg
185826f9f9 bindings/rust: Add description to Cargo.toml 2025-02-18 19:38:36 +02:00
Pekka Enberg
d1e8bb986f Fix RustDoc imports 2025-02-12 17:17:33 +02:00
Pekka Enberg
2e5fc62c45 bindings/rust: Add example.rs 2025-02-12 16:55:05 +02:00
Pekka Enberg
0b83e98031 bindings/rust: Make "limbo_core" workspace dependency 2025-02-12 16:53:41 +02:00
Pekka Enberg
c612b0932e bindings/rust: Rename crate to "limbo" 2025-02-12 16:49:53 +02:00
Aarni Koskela
eaea02c567 Fix a handful of typos 2025-02-09 18:08:29 +02:00
Jorge López
be5ea350bb
bindings: select io_uring feature from limbo_core explicitly as it will be made non-default 2025-02-09 01:10:35 +01:00
Pekka Enberg
7967cc5efc core: Kill Rows wrapper struct
It's just an useless wrapper, kill it.
2025-01-26 16:27:19 +02:00
Jorge López
86a4714711
syntactic changes: remove unneeded paths when the type is already imported 2025-01-18 18:29:12 +01:00
Pekka Enberg
af020c27d6 Initial take on Rust bindings
This implements libSQL compatible Rust API on top of Limbo's core. The
purpose of this is to allow libraries and apps that build on libSQL to
use Limbo.
2025-01-14 09:16:46 +02:00