This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-12-16
Channels
- # adventofcode (43)
- # announcements (31)
- # aws (2)
- # babashka (58)
- # babashka-sci-dev (4)
- # beginners (107)
- # calva (11)
- # cider (25)
- # clj-commons (8)
- # clj-kondo (24)
- # clojure (35)
- # clojure-argentina (1)
- # clojure-europe (25)
- # clojure-italy (5)
- # clojure-nl (11)
- # clojure-norway (39)
- # clojure-spec (11)
- # clojure-uk (3)
- # conjure (2)
- # core-async (19)
- # cursive (33)
- # data-science (2)
- # datomic (50)
- # deps-new (1)
- # emacs (3)
- # events (4)
- # figwheel-main (10)
- # fulcro (63)
- # graalvm (7)
- # holy-lambda (17)
- # introduce-yourself (1)
- # java (15)
- # jobs (1)
- # jobs-discuss (7)
- # malli (24)
- # meander (16)
- # nextjournal (19)
- # off-topic (2)
- # polylith (4)
- # portal (10)
- # re-frame (3)
- # reagent (19)
- # reitit (14)
- # releases (2)
- # remote-jobs (1)
- # reveal (19)
- # shadow-cljs (1)
- # sql (21)
- # testing (4)
- # xtdb (22)
Hi everyone! I'm Carlos, a backend engineer at Nubank who loves Clojure 😄
I've been trying holy-lambda for last few days and I really like it! I'm just running with an issue when trying to compile using bb hl:compile
. It happens when I call the d/connect function (or any other datomic.api function) in my project. If I remove it the problem disappears... Do you have any clue why this might be happening?
It's important to say that the issue is that the terminal blocks 😅
Yes I'm calling it like you say
How should it be done?
Do you know where can I find some docs about it?
(defn connect-to-datomic
[]
(d/connect opts))
(defn start-system
[]
{:datomic (connect-to-datomic)})
;; then in your entrypoint
(... (let [system (start-system!)]
(... do code ...)
// potentially clean up beteen invocations ...)
but the “lazy” solution for you to get your stuff working is just
(def conn (delay (d/connect)))
Works just as you say, thanks for your help!
@U3JH98J4R @U02R05V9NLD very good explanation. Will NuBank use holy-lambda in production?
Btw hl:compile
does nothing special. It's an alias for the command that compiles a project with an AOT, since uberjar
happens locally via depstar now. The reason hl:compile exists is to inform hl:native:conf how the project should be compiled for the GraalVM agent.
Planning to move to tools.build in the next release.
Hi @UJ1339K2B! Awesome, thanks for sharing. At the moment I'm just exploring.