This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2022-10-05
Channels
- # announcements (14)
- # aws (7)
- # babashka (28)
- # beginners (16)
- # calva (2)
- # cider (1)
- # clj-commons (8)
- # clj-kondo (29)
- # clojure (213)
- # clojure-europe (39)
- # clojure-losangeles (2)
- # clojure-norway (9)
- # clojure-spec (2)
- # clojurescript (11)
- # community-development (1)
- # conjure (2)
- # cursive (6)
- # datalevin (2)
- # datomic (8)
- # emacs (29)
- # events (1)
- # fulcro (22)
- # graalvm (14)
- # improve-getting-started (1)
- # jobs (1)
- # lambdaisland (5)
- # leiningen (4)
- # lsp (7)
- # malli (13)
- # meander (11)
- # membrane (13)
- # off-topic (23)
- # polylith (9)
- # re-frame (4)
- # reagent (7)
- # reitit (6)
- # releases (2)
- # sql (58)
- # testing (8)
- # tools-deps (18)
- # web-security (2)
Mornin'
Morning
Good morning!
Dzień dobry!
that's nut bad!
is this the see-if-you-can-talk-with-a-mouth-full-of-marbles challenge
I happen to find myself heading to London this weekend... I believe there are some Londoners here? Maybe we can get a bit of a social Clojure thing going?
So, like sql, monads, and effect systems and stuff. If you write your normal dao fns like (user/find-by-name db name)
or (user/find-by-email db email)
, you can’t really compose them, ie if you want to find a user by name and email you can’t say
(and (user/find-by-name db “Erik”)
(user/find-by-email db “”))
But if you stay in the realm of queries you can, since (in honey sql syntax)
[:and (by-name “erik”) (by-email “”)]
makes total sense.
Not sure where I’m going with this, but I think it’s cool. ya I think this is a key benefit of “data-driven” (like the directions taken in bidi and reitit etc). On the other hand maybe (?) the analog of this in the static typed functional languages are combinators (not sure)
'data is the interface' is something we say a lot in our team 🙂
Something else I've been thinking about is how a schema is a bit like a query, and a mechanism to translate schemas to queries
Yeah. I think if we organize the code in the correct abstract level it's much easier to maintain and compose stuff.
@UK0810AQ2 you got the keyword. Many “advanced patterns” in Haskell etc (from Monad onwards) boils down to using math to make something more “algebra like” (i.e. you’ve got a bunch of operators of the form D x D x D… -> D
and can pretty much freely compose with other operators)
@U04V5VAUN perhaps a bit more remark: I come across similar “pattern/thoughts” of using data-driven + function that generate data to tackle complex SQL query by making it possible to implement abstractions and then compose (like the by-name
function above), and have loved it since then…
… alas, times have changed. If you’re stuck in legacy SQL/RDBMS, then that’s pretty much still almost the state-of-the-art to the best of my knowledge (perhaps generating query guided by the schema is more cutting edge). Then come datalog (and alternative DB architecture) and everything changed.
(Reason for “everything changed” - imo, although I previously conceptualised the query language and the underlying/physical architecture as two separate component of a DB, I later changed my view into “they are different aspects, but can be tightly coupled” and “in the best case, innovations in these two are synergistic” )