This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
- # admin-announcements (11)
- # announcements (1)
- # beginners (80)
- # boot (152)
- # cider (22)
- # clojure (141)
- # clojure-berlin (57)
- # clojure-india (2)
- # clojure-italy (18)
- # clojure-japan (4)
- # clojure-russia (27)
- # clojurescript (96)
- # datomic (6)
- # dunaj (29)
- # editors (1)
- # euroclojure (63)
- # instaparse (2)
- # ldnclj (28)
- # off-topic (36)
- # onyx (4)
- # overtone (1)
- # reagent (8)
wagjo: if you could explain the relationship between clojure and dunaj from the classloader perspective, and the dunaj bootstrapping process
regular dunaj uses custom patched clojure, so I don't know how hard is in boot to remove clojure from dependency tree. In lein I have to explicitly exclude clojure for most of deps...
Regarding bootstrapping, Dunaj first loads a small bootstrapping namespace that introduces enhancements to protocols, deftypes, and provides defXXX macros that support type signatures. Then I gradually introduce more and more features, starting with boolean, host primitives, math facilities ..., while trying to use already implemented Dunaj's features as soon as possible. There were of course some issues with cyclic dependency, toughest one was with core.async. Also dynamic vars cannot be aliased so this was a bit of a pain too. The order in which I've implemented stuff can be seen in a namespaces tab at https://docs.google.com/spreadsheets/d/1J8ndX6C1fuXGdIeekOWsmiqS2tmVb_OMZRKs3SphGPA/pubhtml#
clojure.RT was slightly patched to use Dunaj's collection protocols for seq, get and nth. Otherwise its the same.
micha: yeah one thing that may cause issues in boot. Do not assume some var is referred in namespace you are evaling. always fully qualify symbols/vars if you are evaling them in project's namespace, even stuff from clojure.core.
wagjo: thanks for the explanation! I think that's a good start for my experimentation with dunaj+boot. It's good that RT is more or less compatible because that's something that boot itself uses for its own bootstrapping. I'm hoping to be able to first simply create dunaj pods in boot in which a dunaj repl server can be started. From there we can explore how to fully integrate dunaj, if possible
micha: I'm just learning how boot works and what it provides, so I can't help you with details much
no worries, i was just a little overwhelmed trying to wrap my head around dunaj bootstrapping
is it correct to say that in a full dunaj environment i can use regular clojure libraries? or are there limitations like maybe libraries that depend on access to clojure's java implementation won't necessarily work?
I tried hard to make Dunaj 'backwards' compatible. Most Clojure libraries should work. I'm using it with datomic, ring and friends without problem
Dunaj has its own fork of core.async so this dependency has to be excluded from others libraries you are using together with Dunaj
One more thing, I don't know if it is of any importance, but Dunaj is AOTed before packed into .jar.
no, you have to load clojure and dunaj too, so its actually slower. It was not my goal to lower the startup time, as I wanted it to be backwards compatible...