This page is not created by, affiliated with, or supported by Slack Technologies, Inc.
2021-09-29
Channels
- # aws (8)
- # babashka (45)
- # beginners (83)
- # cider (23)
- # clj-on-windows (4)
- # cljdoc (23)
- # clojars (6)
- # clojure (68)
- # clojure-dev (33)
- # clojure-europe (75)
- # clojure-nl (1)
- # clojure-uk (4)
- # clojurescript (14)
- # conjure (6)
- # data-science (15)
- # datascript (7)
- # datomic (47)
- # docker (15)
- # events (1)
- # fulcro (4)
- # graphql (3)
- # jobs (4)
- # lsp (14)
- # nginx (2)
- # nrepl (2)
- # off-topic (41)
- # pathom (18)
- # pedestal (1)
- # polylith (72)
- # reitit (8)
- # reveal (1)
- # shadow-cljs (48)
- # tools-build (11)
- # tools-deps (24)
- # xtdb (8)
On a recent application I made internal links as [↗️] with vertical-align: super;
on a reporting page that only appear for certain types of users so they can jump to the underlying data directly. I made it so because I wanted to indicate that it is not a link that appears for general users (their clients) so it made sense to make them to look like something “extra” / “put on top”.
But I agree that there is a baseline expectation that this would be an external link with a new tab in many cases.
https://chemaclass.es/readings/97-things-every-programmer-should-know/ For the Kevlin Henney fans
That's a nice summary. I have the book and have read it a couple of times but it's good to see a "bullet point" summary of it like that.
How common is it to use JNI with a non-gc language for substantial parts of a Clojure program? Generally this paradigm/separation seems to be more common in other languages, from JS to Lua, Python etc. Say a full-on webserver, image processing, database layer, handling files… and then exposing a higher level api to the JVM/Clojure. One reason to do this might be performance, another one would be to use specific libraries. Am I correct with the assumption that performance (latency/throughput/memory) are not necessarily that large without considerable fine-tuning? Are there overhead costs? Might it be a much saner to let the JIT compiler to have more code to work with / know about? Asking purely out of curiosity, considering to maybe play with the JNI feature a bit. Happy to read about stories and opinions.
Agreed, I've been using ffi (via JNA) to use c libraries. It works quite well.
I also use @chris441’s library, https://github.com/cnuernber/dtype-next/, which I highly recommend
Ruby and Python generally shovel coal into the C furnace because of performance limitations in Ruby and Python
There are still plenty of good c libraries that don't have good java/clojure counterparts or the java wrappers actually make them more complicated than using them directly via ffi.
I mean JS in of itself is quite fast too (V8), good peak performance. But still, people tend to integrate with non-gc languages for substantial parts (node/deno) on the server side.
I thought that was to provide features that aren't built into v8's js standard library.
Not sure how much I would want to use ffi for performance reasons unless there is an existing library I'm interested in.
I thought that was to provide features that aren't built into v8's js standard library.
well, there are native modules as well. and deno has some modules they wrote in Rust for perf reasons. But I guess those are very specific use-cases
Is there a source that says they wrote the modules in Rust for performance? Just curious.
It seemed sensible that it was perf reasons, I have no official/public statement to share.
Just looking at their docs:
> All APIs that are not web standard are contained in the global Deno
namespace. It has the APIs for reading from files, opening TCP sockets, serving HTTP, and executing subprocesses, etc.
Basically, the only cross platform APIs for those types of OS access are available in c/c++/rust type langs
even the JVM implements their standard library interfaces in c/c++
as far as I know
Yea, I'm mostly just curious since, as you were saying, javascript's v8 usually has fairly good benchmarks
Did they ever end up re-implementing it in rust?
> it is on the roadmap to port it to Rust. (It is also the easiest way to get HTTP/2 and QUIC as well).
aside, the std library also has a couple of wasm (rust) modules: https://github.com/denoland/deno_std/search?l=rust
all those results look like they're all part of the same implementation for crypto digests
docs: https://deno.land/manual/runtime/http_server_apis#http-server-apis code in the cli: https://github.com/denoland/deno/blob/main/ext/http/lib.rs
same, there is an example using dtype-next with ffmpeg that I've been meaning to play with more, https://github.com/cnuernber/avclj