Email or username:

Password:

Forgot your password?
Niki Tonsky

Blown away how much sense using Unix domain sockets for nREPL makes.

We already use .nrepl-port files, right? But instead of using that file directly, we write a number inside and then go to a completely different place to connect.

Well, with Unix domain socket you CAN use that file directly!

Plus:

- No need for port randomization!
- Meaningful names!
- File auto-deletes when your process dies

That's so obvious in retrospect! And yet we all missed it.

Inspired by @mkvlr

6 comments
Simon Gray

@nikitonsky @mkvlr So why isn't it a thing then? 🤔 For cross-platform reasons...?

ldvsoft

@nikitonsky @mkvlr Unix domain sockets are good for IPC, yeah!

Especially is you know that Windows since something in 10 has them too. Not directly on the fs though.

Noah Pederson

@nikitonsky @mkvlr So what do you do when you're on windows and don't have unix domain sockets to use?

Eugen

@nikitonsky @mkvlr unix domain sockets where not supported OOTB in Java until recently. and http client still does not support them yet bugs.java.com/bugdatabase/view (submitted by me ~2years ago. so you had to use native libs.

Niki Tonsky

@ieugen @mkvlr there are two LTS Java releases already that support them, I think it’s pretty stable? Why would you need http client?

Go Up