Commit Graph

1044 Commits

Author SHA1 Message Date
Pekka Enberg
12783ef01e Merge 'bindings/java: Add support for publishing to Maven Central' from Kim Seon Woo
## Purpose
- Deploy `tech.turso:turso:<version>` to maven central so that users can
easily use java bindings
  - For example :
https://repo1.maven.org/maven2/io/github/seonwkim/turso/0.0.1/
## Requirements
- [x] Add the following github secrets.
  - [x] MAVEN_CENTRAL_USERNAME
  - [x] MAVEN_CENTRAL_PASSWORD
  - [x] GPG_PRIVATE_KEY
  - [x] GPG_PASSPHRASE
- [ ] Namespace `tech.turso` must be registered at maven central
- [ ] GPG key registration to key servers
- Notes
  - Retrieve MAVEN_CENTRAL_USERNAME and MAVEN_CENTRAL_PASSWORD from
[maven central](https://central.sonatype.com/usertoken)
  - GPG keys should be registered. You should distribute your keys to
designated(maven central supported) servers
    -  Refer to [GPG key related docs](https://central.sonatype.org/publ
ish/requirements/gpg/#distributing-your-public-key)
    - Btw, I used `keyserver.ubuntu.com` key server while testing
### [Maven Central Username &
Password](https://central.sonatype.com/usertoken)
<img width="2878" height="1338" alt="image"
src="https://github.com/user-
attachments/assets/03e6f967-a7f6-46b8-aef5-d15772bd9eea" />
### [Maven Central
Namespace](https://central.sonatype.com/publishing/namespaces)
<img width="1424" height="456" alt="image" src="https://github.com/user-
attachments/assets/8c0f4f17-bf5a-4c6a-bc47-748d86cd1f1a" />
## Future Works
- Currently, we depend on gradle.properties to determine the version of
our dependency and it's cumbersome to always change the version
manually. Let's find a better solution.

Closes #3624
2025-10-10 13:12:01 +03:00
Jussi Saurio
f9f8eda3c3 Merge 'add Calendar-based timezone conversion support in JDBC4ResultSet' from 김민석
## Summary
Implemented Calendar-based Date/Time/Timestamp getter methods in
JDBC4ResultSet to support timezone conversions.
## Changes
- Implemented `getDate(int, Calendar)` and `getDate(String, Calendar)`
- Implemented `getTime(int, Calendar)` and `getTime(String, Calendar)`
- Implemented `getTimestamp(int, Calendar)` and `getTimestamp(String,
Calendar)`
- Fixed timezone conversion logic (changed from subtraction to addition)
- Added comprehensive test cases for all implemented methods
Test Results
- All tests passed successfully
- New tests validate timezone conversion with UTC and Seoul (UTC+9)

Reviewed-by: Kim Seon Woo (@seonWKim)

Closes #3607
2025-10-09 12:52:09 +03:00
kimminseok
76320e82db lint issues with spotless 2025-10-09 11:19:29 +09:00
kimminseok
f9e95697c8 handle empty string in findColumn() method 2025-10-09 10:46:27 +09:00
kimminseok
76b57e5d0c correctly detect empty ResultSet in next() 2025-10-09 10:29:46 +09:00
Pekka Enberg
17a578a496 bindings/rust: Tokio is not required
The bindings use just async Rust so any async runtime should work.
2025-10-08 11:47:39 +03:00
Dave Warnock
e28ece6950 Update Doc regarding rusqlite compatibility
Make it clear that it's not a drop in replacement for rusqlite as that
isn't async
2025-10-08 08:03:43 +01:00
Kim Seon Woo
3feac63888 Merge branch 'main' into java-bindings-maven-central 2025-10-08 15:50:48 +09:00
Kim Seon Woo
722c906ca6 Change variable names 2025-10-08 15:43:27 +09:00
kimminseok
104c2ffc5e Fix isBeforeFirst to return false for empty ResultSet 2025-10-08 00:40:15 +09:00
kimminseok
043a9fc7b8 Change to verify full exception messages in findColumn tests 2025-10-08 00:25:28 +09:00
Kim Seon Woo
d90d0f3f9f Separate publish.gradle.kts from build.gradle.kts 2025-10-07 23:52:12 +09:00
Kim Seon Woo
e9ccdf15d8 Apply lint 2025-10-07 23:52:03 +09:00
kimminseok
64fd282eb0 Fix NullAway warnings in JDBC4ResultSet 2025-10-07 23:50:48 +09:00
Kim Seon Woo
8af9a53818 Update build.gradle.kts for publishing 2025-10-07 23:37:53 +09:00
Kim Seon Woo
fe7027e8ee Fix Makefile libs command 2025-10-07 23:33:13 +09:00
Kim Seon Woo
76af79c4fa Add javadoc on classes and public methods for publishing to maven central 2025-10-07 23:33:02 +09:00
kimminseok
253d54c15a Fix spotless lint errors 2025-10-07 23:18:35 +09:00
Nikita Sivukhin
bd1013d62f emit proper column information for explain prepared statements 2025-10-07 12:28:55 +04:00
kimminseok
85f2755837 feat(java): implement getTimestamp() in JDBC4ResultSet 2025-10-07 14:30:03 +09:00
kimminseok
ffd43b4b77 feat(java): implement getTime() in JDBC4ResultSet 2025-10-07 14:25:46 +09:00
kimminseok
6adc272d75 feat(java): implement getDate() in JDBC4ResultSet 2025-10-07 14:22:13 +09:00
kimminseok
fb370c63a6 feat(java): implement getRow() in JDBC4ResultSet 2025-10-07 14:18:34 +09:00
kimminseok
fd61ddbd21 feat(java): implement isBeforeFirst(), isAfterLast() in JDBC4ResultSet 2025-10-07 14:15:10 +09:00
kimminseok
80d11b75b1 feat(java): implement getBigDecimal() in JDBC4ResultSet 2025-10-07 14:10:58 +09:00
kimminseok
2aa76709c2 feat(java): implement getCharacterStream() in JDBC4ResultSet 2025-10-07 14:06:59 +09:00
kimminseok
fcb0323218 feat(java): implement findColumn() in JDBC4ResultSet 2025-10-07 14:02:10 +09:00
Nikita Sivukhin
d2dab3d18c fix main workspace dir 2025-10-06 18:30:29 +04:00
Nikita Sivukhin
926fd25cdd move examples to the top-level directory 2025-10-06 18:01:54 +04:00
pedrocarlo
e93add6c80 remove dyn DatabaseStorage and replace it with DatabaseFile 2025-10-03 14:14:15 -03:00
Nikita Sivukhin
f582744819 fix package jsons 2025-10-03 14:44:15 +04:00
Nikita Sivukhin
82d53f8d06 add sync-wasm-vite example 2025-10-03 14:43:23 +04:00
Nikita Sivukhin
d4373379cd remove wasm example 2025-10-03 14:20:18 +04:00
Nikita Sivukhin
17c99de34f accept libsql:// urls generated by the platform 2025-10-03 14:19:36 +04:00
Nikita Sivukhin
515ccfea76 small adjustment 2025-10-03 14:19:07 +04:00
Nikita Sivukhin
73049a0205 add sync node example 2025-10-03 14:18:52 +04:00
Nikita Sivukhin
b67ef8a7eb add basic examples for database-wasm package 2025-10-03 13:23:59 +04:00
Pekka Enberg
7905841990 Turso 0.2.0 2025-10-03 12:20:42 +03:00
Pekka Enberg
3b1d2535de Turso 0.2.0-pre.15 2025-10-03 11:29:43 +03:00
Nikita Sivukhin
9a82a9509f fix sync-engine bug when auth token is provided as dynamic function 2025-10-03 10:50:54 +04:00
Pekka Enberg
b11246278f Merge 'Enable encryption properly in Rust bindings, whopper, and throughput tests' from Avinash Sajjanshetty
This is a follow up from PR - #3457 which requires users to opt in to
enable encryption. This patch
- Makes appropriate changes to Whopper and Encryption throughput tests
- Updated Rust bindings to pass the encryption options properly
- Added a test for rust bindings
To use encryption in Rust bindings, one needs to do:
```rust
let opts = EncryptionOpts {
    hexkey: "b1bbfda...02a5669fc76327".to_string(),
    cipher: "aegis256".to_string(),
};

let builder = Builder::new_local(&db_file).experimental_encryption(true).with_encryption(opts.clone());
let db = builder.build().await.unwrap();
```
We will remove the `experimental_encryption` once the feature is stable.

Closes #3532
2025-10-02 18:32:06 +03:00
Pekka Enberg
78e3311c3b Merge 'Sync engine defered sync' from Nikita Sivukhin
This PR makes sync client completely autonomous as now it can defer
initial sync.
This can open possibility to asynchronously create DB in the Turso Cloud
while giving user ability to interact with local DB straight away.

Closes #3531
2025-10-02 17:25:11 +03:00
Avinash Sajjanshetty
306f681966 Add an encryption test in rust bindings 2025-10-02 19:50:10 +05:30
Nikita Sivukhin
649fddedf6 remove unnecessary clone 2025-10-02 17:31:30 +04:00
Avinash Sajjanshetty
4ee6bdac1b update Rust bindings to pass encryption options 2025-10-02 18:51:44 +05:30
Avinash Sajjanshetty
593fd5fb88 update Rust bindings to enable experimental encryption 2025-10-02 18:50:57 +05:30
Nikita Sivukhin
cff23c80cb fix wasm client 2025-10-02 16:56:54 +04:00
Nikita Sivukhin
39bf35abe9 adjust native sync client 2025-10-02 16:51:08 +04:00
Nikita Sivukhin
863e3fe94e make url parameter to accept either string or function 2025-10-02 16:17:36 +04:00
Nikita Sivukhin
64389447e3 support defered sync in the bindings core 2025-10-02 16:17:36 +04:00