This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2019-12-21
Channels
- # adventofcode (20)
- # babashka (118)
- # beginners (170)
- # calva (1)
- # clojure (102)
- # clojure-europe (1)
- # clojure-nl (13)
- # clojure-uk (5)
- # clojuredesign-podcast (19)
- # code-reviews (10)
- # core-async (9)
- # cursive (7)
- # datomic (8)
- # fulcro (3)
- # malli (5)
- # mount (1)
- # off-topic (19)
- # overtone (1)
- # reagent (2)
- # reitit (2)
- # spacemacs (2)
- # sql (4)
- # tools-deps (5)
In the light of last meetup Clojure/Orm discussion, just stumbled upon https://github.com/metabase/toucan seems like a nice library to give a little bit convenience over HoneySql.
I’ve looked into it, but it didn’t really feel like it make it easier to write queries. Just a bit shorter. It also introduces a lot of complexity with little gain IMHO. It also doesn’t support relations / joins, which is the biggest hurdle. You’d have to fall back to honeysql anyway if you’re making any type of real world app.
My ideal DB library would be one based around spec, which also handles relations (has-many, belongs-to). And compiles down to honeysql for you to query. With spec you could have changesets like Elixir’s ecto: https://hexdocs.pm/ecto/Ecto.Changeset.html
I honestly don’t know why we don’t steal (back) from Elixir, they have a lot of cool ideas imho
But then again. If I’m saying “Why doesn’t anyone build it?“, one can reply with: “So when are you going to start?”
Maybe #malli would even be a better fit, since the schemas are serializable and could be stored inside the db 🙂
Going to start a project to eventually tests several databases. Basic idea is to start with an abstraction of graph-like functions, that could have several implementations depending on db used. A bit like spring-data. Idea for now is to keep it very simple, but to set it up in a way it might become a library at some point.