This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-11-21
Channels
- # announcements (1)
- # babashka (66)
- # beginners (37)
- # calva (3)
- # cljdoc (2)
- # clojure (14)
- # clojure-australia (6)
- # clojure-doc (4)
- # clojure-europe (22)
- # clojurescript (9)
- # datalevin (5)
- # datomic (4)
- # emacs (5)
- # events (1)
- # figwheel-main (6)
- # graalvm (41)
- # lsp (16)
- # luminus (1)
- # off-topic (2)
- # overtone (2)
- # re-frame (2)
- # reagent (8)
- # remote-jobs (1)
- # reveal (49)
- # shadow-cljs (9)
- # spacemacs (14)
- # tools-build (4)
- # tools-deps (16)
What does this part in the doc of read
mean?
:eof - on eof, return value unless :eofthrow, then throw.
if not specified, will throw
user=> (with-in-str "" (read {:eof ::eof :eofthrow true} *in*))
:user/eof
oh got it.
user=> (with-in-str "" (read {:eof :eofthrow} *in*))
Execution error at user/eval159 (REPL:1).
EOF while reading
queues locally - how do? Want to use SQS in prod but something less internet requiring locally.
We've used https://github.com/localstack/localstack a bit at work to mock AWS stuff.
It has worked pretty well for us. All you have to do is change your endpoint URLs, other than that the APIs are the same.
If you just literally want a queue in tests, java util concurrent has good blocking queues
If you want something like a message bus, apache Artemis can be run standalone or embedded in your app jvm (https://activemq.apache.org/components/artemis/documentation/1.0.0/embedding-activemq.html)
Wrap the operations you need in a protocol, use an instance of of a java queue in dev time like hiredman said
I was thinking of even something slightly more generalized and purely behavioral. Once upon a time I toyed around with implementing a generic interface over queues (and implementing it for Kafka, Artemis, core.async, etc) but felt like I was trying to round the circle a bit, so I stopped