Fork me on GitHub
Ferdinand Beyer10:02:31

Finally got around to publish to Clojars: v0.0.49 is available now! refx is a port of re-frame without Reagent, bringing re-frame’s elegance to next-generation React wrappers such as Helix or UIx. Thanks to @rome-user (GitHub handle, not sure if they’re in Slack) for fixing a bug in reg-sub!

👍 15
clojure-spin 8
clojars 4
👏 2
🎉 2

Thanks for your work Ferdinand. I've ported some reitit/re-frame examples to refx as well, if anyone is interested in more samples. The port was 1:1 when looking at re-frame vs refx code:

👍 2
❤️ 3

clojure-lsp Released with fixes, performance and behavior improvements 🎉 There are improvements in hover being able to follow :arglists for documentation, support for cljs docs search on clojuredocs, big performance improvement in completion and more improvements! More details in #CPABC1H61 Thank you for all sponsors and ClojuristsTogether clojurists-together💙

🎉 21
clj-kondo 9
clojurists-together 2
mpenet21:02:46 0.1.13 is updated with the latest Nima release (requires java19+Loom preview)

🎉 5
Tomas Brejla13:02:41

I understand Nima is still relatively new & alpha. But still, I was curious to try apache benchmark against it (or mina). And I was surprised that no matter what value I used for "concurrency" (`-c` ), the benchmark resulted in identical results (total time, requests per second,..) Also the request per second number wasn't too great: ~ 25k req/s on relatively beefy laptop. I've seen better results on "regular old servers" such as httpkit etc. Does benchmarking using ab makes even sense against Nima/Mina? Is is some specific configuration needed in order to get better results?


I recall one benchmark showing 800k req/s on an early nima release, matching the netty impl. of helidon. So I suppose that's likely a config issue and maybe some system level tweaks needed to get there. I haven't run any benchmarks yet myself, but I try to make the code not be wasteful (there are more low hanging fruits, but I don't want to focus on that right now, while in alpha).


if you look at the code involved for reading a req and writing a response it's very thin, I doubt mina is very far from Nima. One thing I will introduce at some point is some "lazy" maps a bit like in aleph to cut down this further, field access would just defer to the underlying method calls and potentially cache values upon access. But not right now.

Tomas Brejla14:02:05

it's definitely a problem in mina, I got same results with some nima example project (maven + java)


what do you mean? same result with Nima and Mina? or very different ones

Tomas Brejla14:02:26

same results 1. (need one more dependency to be added to pom.xml to work) 2. example hello world server using mina both gave me ~25k req/s using ab, at both cases it made no difference when I increased concurrency level


right. well, that could be caused by many things, some config tweaks needed in mina/nima itself or OS level (ulimit & co)

Tomas Brejla14:02:04

I tried checking ulimits and stuff as well, but nothing fishy there. I'll check that TexhEmpower link you mentioned above. Thanks.


I could try to ask the authors to give me some hints on how they achieved 800k for their presentation, they are quite responsive/helpful

👍 1

(there's a helidon slack fyi)

👍 1
Tomas Brejla14:02:46

I'll also try using different tools than ab - or at least check if my distro has the up-to-date version


well ab should be able to go further than 20k r/s, I strongly suspect it's not the issue 🙂

Tomas Brejla14:02:52

it's strange, here's a quick "repro"

(ns httpkitserver.httpkitserver
  (:require [org.httpkit.server :as http]
            [s-exp.mina :as mina]))

(defn app [_req]
  {:status  200
   :headers {"Content-Type" "text/html"}
   :body    "hello HTTP!"})

  ;; httpkit start/stop
  (def server
    (http/run-server app {:port 8080}))
  ;; ab -c 8 -k -n 100000 
  ;;Requests per second:    230394.04 [#/sec] (mean)

  ;; mina start/stop
  (def server-mina
    (mina/start! app {:port 8080}))
  (mina/stop! server-mina)
  ;; ab -c 8 -k -n 100000 
  ;; Requests per second:    20098.54 [#/sec] (mean)


I would guess it could be the config defaults that are more conservative


something like that

Alex Miller (Clojure team)23:02:01

Clojure CLI is now available • Added env var that can be set to temporarily allow support for http repos: CLOJURE_CLI_ALLOW_HTTP_REPO • Remove deprecated support for -R and -C • Clean up help text around repl supporting init-opts

🎉 6
clojure-spin 10

hi @U064X3EF3 thanks for the new release. could you direct me to where i can find more information on CLOJURE_CLI_ALLOW_HTTP_REPO? can't find it in either cli or tools repos, nor on the TDEPS jira. wondering what it is? thanks

Alex Miller (Clojure team)12:02:32

I haven’t doc’ed it yet, but it’s exactly what it says above - an env var that can be set to allow use of Maven repos with http urls (which are disallowed otherwise)

👍 1