I'm excited to announce a new language binding that connects Nim with YottaDB, a fast, hierarchical, key-value database engine designed for high-performance, transaction-processed applications.
YottaDB is:
💡 What Does the Nim Binding Offer?
Nim is now listed as another language to access YottaDB (https://docs.yottadb.com/MultiLangProgGuide/index.html) 🔗 Learn More Check out the full blog post on the YottaDB site: 👉 Nim Meets YottaDB (https://yottadb.com/nim-meets-yottadb)
The project is available on https://github.com/ljoeckel/nim-yottadb
I'm sorry if that came across as a sales pitch.
To the contrary, I was asking for a sales pitch! ;)
Rather, I'm more interested in what got you interested in YottaDB. The standard list of features is good, but it's more interesting to hear about personal reasons.
For me personally, the flexibility of a hierarchical key-value database was very interesting, as it allows you to map practically all other data models. Relational, graph, JSON, etc.
That's pretty interesting. Usually key-value don't support relational or other things.
With the current Nim/YottaDB binding, I can write 4.1 million records per second on a Mac Mini M4 and traverse the index at 6.5 million records per second
Okay, that's pretty fast. Does it support transactions?
Personal Interest: My plan is to build a "Media Container" that has all the media-data and meta data in one place. Is safe, can be easily replicated and so on.
Relational Support: https://yottadb.com/product/octo-sql-for-analytics/ As far as i know they use Postgresql wire protocol, so that any jdbc, odbc, ole db driver should work. I've never tried for myself.
Transactions: Yes, they have transactions. I've made some benchmarks with/without WriteAheadLog and Transaction boundaries. See code and results below.
proc myTxn(p0: pointer): cint {.cdecl.} =
let i = $cast[cstring](p0)
try:
ydb_set("^GBL", @[i], i)
except:
return YDB_TP_ROLLBACK
YDB_OK # commit the transaction
# with Transaction
timed:
for i in 0..10000000:
let rc = ydb_tp(myTxn, $i)
if rc != YDB_OK:
echo "Error ", rc
# without Transaction
timed:
for i in 0..10000000:
ydb_set("^GBL", @[$i], $i)
#discard ydb_get("^GBL", @[$i])
Empty database for each run created
WriteAhead Duration Duration
Operation Log 1. run 2. run threads Transaction
Set Off 4456 ms 3917 ms on
Get Off 3123 ms on
Set On 4315 ms 4091 ms on
Get On 3101 ms on
Set Off 2394 ms 2044 ms off
Get Off 1380 ms off
Set On 2402 ms 2076 ms off
Get On 1557 ms off
Set On 3583 ms 2994 ms off yes