Clojure – comparison of gnuplot, Incanter, oz/vega-lite for plotting usage data

What is the best way to plot memory and CPU usage data (mainly) in Clojure? I will compare gnuplot, Incanter with JFreeChart, and vega-lite (via Oz). (Spoiler: I like Oz/vega-lite most but still use Incanter to prepare the data.) The data looks like this: ;; sec.ns | memory | CPU % 1541052937.882172509 59m 0.0 1541052981.122419892Continue reading “Clojure – comparison of gnuplot, Incanter, oz/vega-lite for plotting usage data”

Beware the performance cost of async_hooks (Node 8)

I was excited about async_hooks having finally landed in Node.js 8, as it would enable me to share important troubleshooting information with all code involved in handling a particular request. However it turned out to have terrible impact of our CPU usage (YMMV): This was quite extreme and is likely related to the way howContinue reading “Beware the performance cost of async_hooks (Node 8)”

Troubleshooting javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure

Re-published from the Telia Tech Blog. The infamous Java exception javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure is hardly understandable to a mere mortal. What it wants to say is, most likely, something like this: Sorry, none of the cryptographic protocols/versions and cipher suites is accepted both by the JVM and the server. For instance the serverContinue reading “Troubleshooting javax.net.ssl.SSLHandshakeException: Received fatal alert: handshake_failure”

Experience: Awesome productivity with ClojureScript’s REPL

Re-posted from Telia’s tech blog. What’s the deal with ClojureScript? How can you justify picking such a “niche” language? I have recently experienced a “wow” session, demonstrating the productivity gains of ClojureScript and the interactive development it enables thanks to its REPL. I would like to share the experience with you. (If you have neverContinue reading “Experience: Awesome productivity with ClojureScript’s REPL”

Storytelling as a Vehicle of Change: Introducing ClojureScript for the Heart and Mind

People don’t really like changes yet change we must in this fast-developing world. How to introduce a change, or rather how to inspire people to embrace a change? That is one of the main questions of my professional life. I have recently talked about Functional programming (FP) in JavaScript and compared it to ClojureScript, whichContinue reading “Storytelling as a Vehicle of Change: Introducing ClojureScript for the Heart and Mind”

An answer to CircleCI’s “Why we’re no longer using Core.typed”

CircleCI has recently published a very useful post “Why we’re no longer using Core.typed” that raises some important concerns w.r.t. Typed Clojure that in their particular case led to the cost overweighting the benefits. CircleCI has a long and positive relation to Ambrose Bonnaire-Sergeant, the main author of core.typed, that has addressed their concerns in hisContinue reading “An answer to CircleCI’s “Why we’re no longer using Core.typed””

Refactoring & Type Errors in Clojure: Experience and Prevention

While refactoring a relatively simple Clojure code to use a map instead of a vector, I have wasted perhaps a few hours due to essentially type errors. I want to share the experience and my thoughts about possible solutions since I encounter this problem quite often. I should mention that it is quite likely thatContinue reading “Refactoring & Type Errors in Clojure: Experience and Prevention”

Example: Functional Reactive Programming decisively beats Imperative on simplicity, length

@theburningmonk Yan Cui has a nice example demonstrating how Functional Reactive Programming [slides 185 – 206] (with Elm’s Signals) yields a much shorter and easier to understand (one you know FRP) code than an imperative code with mutations spread all over the code base. The game Use the Up and Down keys to move the platforms and thusContinue reading “Example: Functional Reactive Programming decisively beats Imperative on simplicity, length”

A Usable Node.js REPL for Emacs

Being used to the excellent REPL in Clojure(Script), I was surprised to find out that Node.js REPL is somewhat weak and that its support in Emacs is not actively maintained. I anyway managed to get a usable REPL with these three components: The Emacs nodejs-repl package (nearly 2 years old) J. David Smith’s nodejs-repl-eval.el toContinue reading “A Usable Node.js REPL for Emacs”