Better HN
topnewbestaskshowjobs
Log inSign up

refset

1,514 karma · joined Aug 24, 2015 (11y ago) · 537 submissions

https://github.com/refset

[ my public key: https://keybase.io/refset; my proof: https://keybase.io/refset/sigs/pyTK0thu8g5O4Zs7EA3HrQYKkYZjeEz_TUr8nZV2hlY ] c0ba44896414421c9009bc8a77a86ceb

meet.hn/city/51.0612766,-1.3131692/Winchester

Socials: - github.com/refset

---

Submissions

comment 7y ago · link · parent

For more context on the Polis platform, watch "Clojure on the cyberpunk frontier of democracy" https://www.youtube.com/watch?v=2tBVMAm0-00

comment 7y ago · link · parent

These are good reasons to use a bitemporal database [1].

A log gives you "transaction time" but you need to create an efficient representation of "valid time" for backfilling and corrections.

[1] https://en.wikipedia.org/wiki/Temporal_database

Disclosure: I work on a database for Kafka that provides point-in-time bitemporal Datalog queries https://github.com/juxt/crux

comment 7y ago · link · parent

EQL as a pull syntax for Crux is definitely interesting (and we're considering building something more official): https://github.com/souenzzo/graph-demo

comment 7y ago · link · parent

Nubank recently raised $400M at a $10B valuation and they depend on Datomic [1] heavily for their core systems [2].

The RDF database marketplace is very established [3], and the likes of MarkLogic, DB2, and Oracle have clearly encountered profitable reasons to add RDF support. I believe RDF has good traction in knowledge-intensive industry domains such as clinical research and life sciences.

Disclosure: I work on Crux [4] which adds bitemporal versioning and eviction to a document->triplestore model running on top of Kafka.

[1] https://www.datomic.com/customers.html

[2] https://www.datomic.com/nubanks-story.html

[3] https://en.wikipedia.org/wiki/Comparison_of_triplestores

[4] https://github.com/juxt/crux

comment 7y ago · link · parent

Author here. Crux [1] (MIT license) is currently still alpha but the supported beta release is arriving in September. We also know of two companies deploying Crux into production in the next week or so. We will be making further announcements during our talk at Strange Loop [2].

[1] https://github.com/juxt/crux

[2] https://www.thestrangeloop.com/2019/temporal-databases-for-s...

486.

Show HN: Create an unbundled database with Crux and Confluent Kafka in 5 minutes(juxt.pro ↗)

12 points · by refset · 7y ago · 1 comment

comment 7y ago · link · parent

GraphBLAS is also the engine behind RedisGraph. Sparse adjacency matrices are interesting from a graph database perspective in particular because they are typically faster and more compact than the mainstream index-free adjacency systems (e.g. Neo4j).

comment 7y ago · link · parent

The sibling response from fulafel is definitely the central argument. I would also add that Clojure has excellent production-quality "interop" with all of its host languages, such that end-to-end ergonomics are relatively painless e.g. CLJS<->JS<->Graal Polyglot<->Java<->Clojure

There was briefly (now deleted) a response to fulafel's comment which essentially pointed out how JavaScript itself should be considered a production-quality language that is up to the task. After all, JavaScript can also now be used to build JVM applications thanks to GraalJS ...except I wouldn't bet on that technology direction gaining much traction at this point in time (unless maybe Oracle has a trick up its sleeve).

comment 7y ago · link · parent

> we switched our production JVM to GraalVM, which opened a new possibility since it comes with GraalJS, a JavaScript engine which aims to compete with today's faster JavaScript engines like V8 and JavaScriptCore on performance. It lets us embed the ClojureScript app into our Clojure app so it can perform the rendering in-process in the JVM

> GraalVM's polyglot abilities to load the JavaScript artifact from the ClojureScript app into the Clojure JVM and directly call the function with almost no overhead

I think Clojure is uniquely positioned here in its ability to fuse these JS<->JVM technologies using a single language and, in this instance, fully supplant the need for nodejs. Very impressive!

comment 7y ago · link · parent

Since stepping into a new role in the world of full-time Clojure earlier this year I have been almost entirely focussed on launching an ambitious new open source graph database that uses Kafka as the "unbundled" transaction log and provides bitemporal Datalog queries: https://github.com/juxt/crux

Before I made this move, tinkering with Clojure and thinking about databases was just a hobby.

I wasn't around when Crux was initially designed and built, but my primary job so far as the product manager for Crux has been to figure out how we make the most of all the ingenuity and effort that's already gone into it. I also wear many additional hats at the moment: leading the development team, managing community interactions, speaking at events/conferences, creating the marketing, and working on sales & strategic partnerships.

This all keeps me incredibly busy but it is fun and it feels like the right thing for me to be working on and thinking about at this point in my life. I think of it like the perfect side-project that I am very fortunate to be able to work on all day long (and surrounded by excellent & talented people!).

comment 7y ago · link · parent

It's the other covering indexes (i.e. AVE, AEV, VAE) that make it interesting because they allow the query engine to perform efficient ad-hoc graph traversals.

comment 7y ago · link · parent

Definitely CP. With Eva and Datomic, transactions are serialised through a single transactor node at a time.

The transaction log design is a fundamental design tradeoff that Eva/Datomic/Crux share, which means system throughput is limited by the throughput of a single process. The argument in favour of such a design is that most businesses & business applications don't actually experience transactional data volumes over 10K tx/sec.

comment 7y ago · link · parent

I think to be really useful an event sourcing data store needs `as at` support in addition to `as of` (i.e. bitemporality) to cope with retroactive and proactive events and corrections. There are a couple of references for this in the Crux docs: https://juxt.pro/crux/docs/bitemp.html#_known_uses

comment 7y ago · link · parent

Well, Eva overlaps very closely with Datomic so I would recommend taking a look at the FAQ entry I wrote on the Crux/Datomic comparison (with 8 sections covering the major differences!): https://juxt.pro/crux/docs/faq.html#_comparisons

`EAV+T+added?` is the canonical data representation used by Eva, whereas Crux relies on two discrete "document" and transaction logs as the canonical representation. There are many reasons for this (data eviction, "unbundled" scalability etc.) but bitemporality (i.e. the ability to transact into the past/future) is definitely the primary reason why Crux doesn't follow the `EAV+T+Added?` pattern. You can get a feel for the indexes Crux uses here: https://github.com/juxt/crux/blob/master/src/crux/codec.clj#...

comment 7y ago · link · parent

I don't know for sure, but I suspect there is a significant usability difference between an "EAV pattern" and something engineered from the ground up to make EAV practical.

comment 7y ago · link · parent

Interesting, I was fairly confident you were going to write about Datalog and about the flexibility of having such a minimal and evolvable schema :)

One of the motivations for Crux was that `as-of` queries still weren't powerful enough for what the business really needed, which was something like `as-of` that could cope with retroactive corrections for out-of-order and delayed ingestion (of upstream transaction data).

comment 7y ago · link · parent

> time as a first class citizen

It's worth noting that time now has two levels of meaning in this context - transaction time and valid time.

Disclosure: working on Crux

comment 7y ago · link · parent

To be specific, the picture I am thinking about in particular is described in a slide titled "Local consistency points in the absence of Global Consistency" (from this talk: https://youtu.be/VYOMmwkdSig?t=1817), where it shows how each local consistency point is ideally implemented using ES/CQRS. I also agree that the tools Confluent are currently providing us with today do not make this trivial.

Edit: the other big picture Confluent quote I like is "You are not building microservices, you are building an inside-out database" (Tim Berglund, Confluent, 2018) which is a perfect answer to this other quote: "The hardest part of microservices is your data" (Christian Posta, Red Hat, 2017)

comment 7y ago · link · parent

I agree, the Confluent team paint a very clear big picture. You may be interested to take a look at Crux [0], a general purpose document database with bitemporal graph queries, implemented as an ES/CQRS system directly on top of Kafka (or a local KV store).

We created Crux because we found ourselves routinely needing bitemporal functionality when building immutable systems that are capable of ingesting and interpreting out-of-order/late-arriving events [1].

So far we have decided against using Kafka Streams to keep our log-storage options very pluggable, but we pretty much implement the same mechanics.

Disclosure: product manager for Crux :)

[0] https://juxt.pro/crux/index.html

[1] https://juxt.pro/blog/posts/introducing-crux.html

comment 7y ago · link · parent

Offering Manager for Crux here - all feedback is very welcome!

Another cool thing we haven't highlighted or documented anywhere yet is GraalVM support for the "standalone" deployment mode...which is mostly just for anyone who particularly dislikes the idea of using a plain old JVM :)

comment 7y ago · link · parent

Clojure is very pleasant to work with and is exceptionally useful for rapid development. My colleagues at JUXT certainly would not have been able to build our new bitemporal Datalog database [0] without it!

[0] https://juxt.pro/blog/posts/introducing-crux.html

502.

Show HN: Crux, an open-source bitemporal Datalog database(juxt.pro ↗)

18 points · by refset · 7y ago · 1 comment

comment 7y ago · link · parent

This is really neat - great work! It took me less than 10m to figure out how to copy a Crux tutorial into Nextjournal using the Clojure template: https://nextjournal.com/crux/a-bitemporal-tale

The only issue I encountered was that adding comments after the final close parens in the code sections creates EOF errors.

comment 7y ago · link · parent

Cool, thanks for the summary! The user-defined indexes sound particularly intriguing.

The documentation page alludes to payroll, audit and decision support applications -- have you implemented one or more of those already? I have been compiling a list of known uses for bitemporality in the Crux docs which you are more than welcome to borrow from:

https://juxt.pro/crux/docs/bitemp.html#_known_uses

It is great to see all this new enthusiasm for temporal databases now that they are finally viable, decades after all the major research happened :)

comment 7y ago · link · parent

It would be interesting to hear about the use-cases that prompted the creation of Sirix. For example, we were inspired to build Crux[0], another bitemporal document database (although we opted for Datalog rather that XQuery), following our experiences of integrating timestamped data from multiple upstream systems, whilst coping with delays and ad-hoc corrections, and also maintaining efficient time-travel auditability.

[0] https://juxt.pro/crux

comment 7y ago · link · parent

"some functionality is lacking before Beam could be used as a critical production data store, including deletion of facts"

It sounds like this needs a second central log to enable eviction of sensitive data before it can be seriously considered usable. One log for transactions and another other for the data itself. Or at least that is the conclusion we reached when designing and building our own knowledge graph store (with a similar use of Kafka): https://juxt.pro/crux/docs/index.html#_unbundled

comment 7y ago · link · parent

As the product manager for Crux I must point out that we are not currently optimised for time series queries, as there is no columnar compression in the core bitemporal indexes. It is certainly something we have thought about however. For instance, we have already translated a couple of TimescaleDB examples into our own test suite [0][1] and we have created a sample aggregation "decorator" that sits on top of the Datalog queries [2].

Whilst there are no immediate plans from the core team to add columnar compression or otherwise improve our support for time series use cases, I think that a lot can be readily achieved by building on top of what already exists in the core. I very much look forward to seeing others experiment with the possibilities here.

[0] https://github.com/juxt/crux/blob/master/test/crux/ts_device...

[1] https://github.com/juxt/crux/blob/master/test/crux/ts_weathe...

[2] https://github.com/juxt/crux/blob/master/test/crux/decorator...

comment 7y ago · link · parent

Take a look at Scuttlebutt [0] which works on very similar principles of authenticated log replication.

Also note that Lotus Notes [1] has been doing all this replicated encrypted app platform stuff since the early 90s.

I am working on a log-centric bitemporal database at JUXT which I think intersects with this problem space as well, see my recent tweet relating to the article [2].

[0] https://www.scuttlebutt.nz/applications

[1] https://web.archive.org/web/20170228160130/www.kapor.com/blo...

[2] https://twitter.com/refset/status/1124311089943019521

comment 7y ago · link · parent

For me it was the draw of Datomic and DataScript. Clojure is a neat language, but I feel like how we store, retrieve and transmit data is vastly more important.

comment 7y ago · link · parent

My mind immediately jumps to thinking about branching valid time timelines, but having thought about this a _lot_ over the last few months I think actually all other kinds of timelines can be implemented using valid time + additional indexing.
1
1415161718