Hacker Newsnew | past | comments | ask | show | jobs | submit | davidtos's commentslogin

I am still working on Java bindings for io_uring https://github.com/davidtos/JUring

The goal is to bring fast random read/writes to Java. Fun project with lots of great challenges around performance while maintaining a nice API.


Working on creating Java bindings for io_uring. Trying to get some better performance by batching downcalls and making the API Java friendly.


I did some similar testing a few days ago[1]. Comparing platform threads to virtual threads doing API calls. They mention the right conditions like having high task delays, but it also depends on what the task is. Threads.sleep(1) performs better on virtual threads than platform threads but a rest call taking a few ms performs worse.

[1] https://davidvlijmincx.com/posts/virtual-thread-performance-...


That already exists luckily, you can even change the maximum number of carrier threads with:

- jdk.virtualThreadScheduler.maxPoolSize=10


The default is 256, way higher than 10.

But of course, when you have thousands of Virtual Threads all deliberately pinning the carrier thread, you quickly run out.


I suppose that a hard limit on the number of carrier threads is a sensible choice then - deadlock is better than creating threads until the system grinds to a halt.

But then again, why couldn't scheduler detect a deadlock? Go has a system in place that, in case of total program deadlock, prints out an error message with all goroutines' stack traces, and stops the program. Perhaps Virtual Thread Scheduler could do the same thing?

But then again, Java also allows for native threads to run in parallel to Virtual Threads, which makes it impossible to detect whether there's a deadlock, and not just virtual threads waiting on a native thread.

I suppose this is a very good example why simple is better than complex.


This is exactly what i do. Pressing the leader key and another key to let it type sentences and boiler plate code.

Creating a layer for this sort of typing would also be really cool and not having to use that leader key the entire time.


https://www.davidvlijmincx.com/

I write mostly about concurrency and testing in Java for the last two years now.

I do it in hope that it helps people and to connect with people who share the same passion :D


I have been writing for my personal blog now for a year. The time spend writing and editing does feel worth it. My writing is a lot better than it was a year ago.

It helped me to get noticed at my work and to make new connections.

You will always learn something about the stuff you write. To write better, some new way of doing something, or something from the comments.

I run my blog through cloudflare pages. I only have to push a new markdown file to github and the Hugo template and cloudflare do the rest. Took only a few hours to setup correctly.


> You will always learn something about the stuff you write. To write better, some new way of doing something, or something from the comments.

This. While you try to explain something to the potential reader, you will notice some holes in your own understanding. Teaching/explaining helps you become better at something.


Writing and communication is an engineering superpower. Writing critically about anything is still a good exercise.


https://www.davidvlijmincx.com/

I write mostly about Java, testing and future additions to the language.


Shameless plug of my blog. It’s about new and upcoming features in Java and unit testing. https://www.davidvlijmincx.com/


Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: