This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2016-11-14
Channels
- # beginners (110)
- # boot (50)
- # cider (29)
- # cljs-dev (80)
- # cljsrn (10)
- # clojure (54)
- # clojure-italy (3)
- # clojure-korea (24)
- # clojure-russia (50)
- # clojure-spec (12)
- # clojure-taiwan (1)
- # clojure-uk (67)
- # clojurebridge (14)
- # clojurescript (118)
- # component (3)
- # cursive (11)
- # datomic (28)
- # dirac (31)
- # emacs (45)
- # flambo (2)
- # hoplon (53)
- # immutant (3)
- # jobs (5)
- # mount (8)
- # off-topic (10)
- # om (5)
- # onyx (52)
- # other-languages (2)
- # parinfer (1)
- # pedestal (1)
- # proton (39)
- # protorepl (2)
- # re-frame (22)
- # remote-jobs (1)
- # ring (13)
- # ring-swagger (2)
- # test-check (9)
- # untangled (28)
- # vim (12)
not sure what answer i'll get at this hour, but did something change in the 1.9 alpha that would break :refer-macros? i have [om.next :as om :refer-macros [defui ui]]
and am getting a compile error: "Only :as, :refer and :rename options supported in :require"
I think :refer-macros is no longer needed in recent 1.9? https://groups.google.com/forum/#!searchin/clojurescript/ANN%7Csort:date/clojurescript/a7KnSSwJsbk/cwv0RduyCwAJ
NP! That was what I inferred. Have not tested myself cuz am still with 1.8x at work.
I’m having trouble finding the documentation for #? and while on the topic, is there no nicer way to require libraries where, depending on the arch, I may need :refer/:refer-macros ?
@iku000888 much appreciated 🙂
I like simply logging to papertrail
is there an easy way to get baz from a symbol ‘foo.bar.baz without converting to a string?
I don't think so.
if you want 'baz
(the symbol), then no. if you want "baz"
(the string), then a substring of the name of 'foo.bar.baz
might not be what you call a "conversion".
@borkdude depending on what you're worried about, it might not matter: the string "foo.bar.baz" already exists, calling name
doesn't involve any work
but substringing does of course
@gfredericks In this case I’m not worried, just lazy
boot.user=> (Paths/get "foo" (to-array ["bar"]))
java.lang.ClassCastException: [Ljava.lang.Object; cannot be cast to [Ljava.lang.String;
@chrisblom that works, thanks
there's a simulated async upload here http://www.braveclojure.com/core-async/ in the alts section. perhaps that's enough to get you going
Hey all. Is anyone using the component system? I'm just wondering what's the current best practice to restart system in production setting. I'm having the ZooKeeper close the connection due to inactivity, and I'd need to do a reconnect. I'd also could do wrap the connection in an atom and swap! the new one in there.
@mikko, can't you make the zookeeper driver reconnect automatically if the cx is lost?
that seems like something the driver should abstract away
like a connection pool
@pesterhazy I'm using https://github.com/liebke/zookeeper-clj which does not support that as I know
So I was thinking that it should be a decent idea if I could just restart the whole system when that happens 🙂
But then again, adding a watcher and embedding the connection into an atom is also a viable solution in my book.
I wouldn't restart the entire system
It seems like an overkill, yes, definitely. It's just that the system is built in a way that should not present any problems, I do it all the time on development.
the other suggestion seems better: (defn get-connection [cmp] (if (is-active? cmp) @(:connection cmp) (do (re-connect cmp) @(:connection cmp))
something like that to paper over the fact that connection may be lost on the way
Sounds good. Maybe I'll go along those lines. Thanks @pesterhazy!