Home » Community » U++ community news and announcements » Unix Domain Sockets Support Added to U++.
| Unix Domain Sockets Support Added to U++. [message #61889] |
Sat, 06 December 2025 14:11  |
Oblivion
Messages: 1248 Registered: August 2007
|
Senior Contributor |
|
|
Hi,
Unix Domain Sockets Support Added to U++.
The socket API (renamed to Upp::Socket) now fully supports Unix domain sockets on POSIX systems, including both filesystem-based sockets and (on Linux) abstract namespace sockets.
New methods:
- ConnectFileSystem / ListenFileSystem: POSIX-wide, bind/connect using a regular filesystem path.
- ConnectAbstract / ListenAbstract: Linux-only, using the abstract namespace (no filesystem entry).
This should make local IPC faster, cleaner, and more flexible across platforms. Feedback and testing are welcome!
Best regards,
Oblivion
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
| Re: Unix Domain Sockets Support Added to U++. [message #61900 is a reply to message #61889] |
Sat, 13 December 2025 15:50   |
Tom1
Messages: 1317 Registered: March 2007
|
Ultimate Contributor |
|
|
Hi İsmail,
Thanks for the news! I was pleased to read about this interesting and important piece of work. As I currently do not have much time to dig into your implementation properly, can you tell me if you included support for Windows 10/11 too? Windows is supposed to support AF_UNIX since about 2017... although not abstract socket namespace.
Do you have any Client/Server sample code that demonstrates and possibly benchmarks the IPC between them? It would be interesting to see how localhost loopback (AF_INET) compares with this.
Best regards,
Tom
|
|
|
|
| Re: Unix Domain Sockets Support Added to U++. [message #61901 is a reply to message #61900] |
Sat, 13 December 2025 17:56   |
Oblivion
Messages: 1248 Registered: August 2007
|
Senior Contributor |
|
|
Hello Tom,
Quote:
Thanks for the news! I was pleased to read about this interesting and important piece of work. As I currently do not have much time to dig into your implementation properly, can you tell me if you included support for Windows 10/11 too? Windows is supposed to support AF_UNIX since about 2017... although not abstract socket namespace.
I actually wasn't aware of that until you mentioned it 
I've been working almost exclusively on Linux for years, so I must have missed that development.
That said, since the Socket class already abstracts things in a fairly portable way, and only connection creation and listening need to be handled separately, it should be quite straightforward to add Windows support as well. At the moment, it is available only on POSIX systems
I'll check and verify this as soon as possible.
Regarding performance, I didn't include any dedicated benchmarks. The U++ nightlies already contain UnixSocketClient and UnixSocketServer examples, which are essentially the same as the SocketClient and SocketServer examples. Based on my experience (outside of U++), Unix domain sockets are generally faster for local IPC, as they avoid the TCP/IP stack overhead.
Moreover, performance was not the only motivation. Many system services (such as the notorious D-Bus) rely exclusively on Unix domain sockets.
In any case, I'll follow up with some benchmarks.
Best regards,
İsmail
Github page: https://github.com/ismail-yilmaz
Bobcat the terminal emulator: https://github.com/ismail-yilmaz/Bobcat
|
|
|
|
|
|
|
|
|
|
Goto Forum:
Current Time: Sun Dec 14 01:15:50 CET 2025
Total time taken to generate the page: 0.07407 seconds
|