News for hackers. Stuff that matters.
Re:.NET 6 Preview 5 by gameswithgo on Friday June 18, 2021 @10:56AM (#27551013)
If it has been a few years since you looked at C# or F#, it may be worth a look again now. Lots and lots of optimizations have been added in the last 5 years, and you can even use SIMD intrinsics directly now. By some measures C# is now the best overall performing garbage collected language (Such as The Benchmark Game)
Re:.NET 6 Preview 5 by Someone1234 on Friday June 18, 2021 @11:10AM (#27551171)
One of the biggest things was the addition of Span<T> and Memory<T>, and their usage in underlying types within the .Net framework. While C# always had the ability to use raw pointers, these two types allow you similar performance characteristics without unsafe blocks (and frankly are near idiot-proof instead of being a giant foot-gun with pointers to managed types).

https://docs.microsoft.com/en-us/dotnet/standard/memory-and-...

Re:.NET 6 Preview 5 by Thaxll on Friday June 18, 2021 @11:10AM (#27551178)
"By some measures"

By some other measure it's not, out the three fastest: Java/C#/Go they're all pretty much as fast.

Re:.NET 6 Preview 5 by manigandham on Friday June 18, 2021 @11:14AM (#27551213)
Add in the massive standard library, project types, and overall productivity and it's the best platform available now.

I'm working in production projects across all 3 languages now and Java and Go are way behind when it comes to producing a polished product as quickly as possible.

Re:.NET 6 Preview 5 by Thaxll on Friday June 18, 2021 @11:23AM (#27551317)
C# is not even close to Java in term of libraries.
Re:.NET 6 Preview 5 by NicoJuicy on Friday June 18, 2021 @11:28AM (#27551373)
Which are missing? :)

There are currently 244,641 libraries through nuget

https://www.nuget.org/packages

Ps. You can use libraries from f#, c# and VB.net. So as a .net developer, your statement doesn't make any sense.

You could have mentioned the different frameworks. But there is interop through the CLR between languages.

Re:.NET 6 Preview 5 by pionar on Friday June 18, 2021 @11:56AM (#27551686)
Eh, I've been a .net developer for almost 15 years.

The parent post is correct that the third-party ecosystem (especially OSS) is sorely lacking in quality.

Like look at logging - logging in .net is SO anemic. Even with third-party libs, there are so many features missing that have been in java libs like slf and log4j2 for years, yet we have nothing close in .NET.

Hell, you could just pick a feature from spring and compare to what's available in .NET ecosystem, and you'll be sorely disappointed.

Re:.NET 6 Preview 5 by ceesharp on Friday June 18, 2021 @11:58AM (#27551719)
Can you give an example what is missing in e.g. Serilog?
Re:.NET 6 Preview 5 by pionar on Friday June 18, 2021 @12:26PM (#27552015)
The ability to change logging levels of either a category or all categories at runtime is one.

Being able to monitor levels via an administrative endpoint.

A decent rolling file implementation that can compress the archived files.

These are all things I've had to implement (on top of serilog, no less) in the past year.

log4j2 has these out of the box.

Re:.NET 6 Preview 5 by gokhan on Saturday June 19, 2021 @09:05AM (#27560128)
> The ability to change logging levels of either a category or all categories at runtime is one.

LoggingLevelSwitch?

> Being able to monitor levels via an administrative endpoint.

I wrote actuator endpoints for this one, was not hard but yeah.

> A decent rolling file implementation that can compress the archived files.

serilog-sinks-file has FileLifecycleHooks?. There's OOB serilog-sinks-file-gzip but you can also implement your own.

Re:.NET 6 Preview 5 by NicoJuicy on Saturday June 19, 2021 @03:00AM (#27558416)
Nlog Elmah ( .net framework)

All the sinks for whatever you want.

Re:.NET 6 Preview 5 by manigandham on Friday June 18, 2021 @11:35AM (#27551452)
Quantity of libraries is a poor metric. Like I said, the standard library in .NET covers a lot, and lets you make everything from CLIs to enterprise web apps. And when you do need 3rd-party code, there are plenty of commercial and OSS options to solve your problem.
Re:.NET 6 Preview 5 by EvilEy3 on Friday June 18, 2021 @01:30PM (#27552739)
It's not just quantity. Java benefits from all the major players that are using it. Quality of libraries is head and shoulders above anything you can find in .NET world.
Re:.NET 6 Preview 5 by manigandham on Saturday June 19, 2021 @10:19AM (#27560634)
I don't think so anymore. It used to be that way but .NET has massively changed in the last few years. Also many of the Java libraries are unnecessary in the .NET because of its strong standard library and core frameworks. There's no need for 20 different JSON serializers or webservers. In contrast, there's nothing even close to Blazor for Java.
Re:.NET 6 Preview 5 by sremani on Friday June 18, 2021 @12:00PM (#27551729)
Many of the .net libraries are poor afterthoughts of an existing Java library.

Java simply has developer mindshare, the .Net developer stereotype is so rigid and engrossed that the pay difference between a .Net dev and their Java peer is usually around 20% if not more.

Re:.NET 6 Preview 5 by aksss on Friday June 18, 2021 @04:17PM (#27554502)
your average .net dev gets paid less than your average COBOL dev too, but I wouldn't say that informs us of much other than scarcity of expertise. We used to say, "you can through a rock into a crowd and find somebody who can at least be productive on .net". Finding a stone cold expert on .Net is far more difficult, but for the average enterprise doing internal development weighing whether to adopt one platform or another, resource availability/scarcity matters.
Re:.NET 6 Preview 5 by sremani on Friday June 18, 2021 @09:48PM (#27557028)
The confusion here is perhaps that I jumped from B to F. The number of successful Opensource projects in Javaworld are astounding, and the OSS/Library work in .net is there but in comparison is miniscule. That feeds into the stereotype of .net developers being cookie-cutter VB-eseque Enterprise developers, which even feeds into their pay.

JavaWorld is bigger and Java developer count exceeds .net developer count, so the whole scarcity thing is a static explanation of a much complex dynamic environment. The intent here is not to complain about .net dev wages.

Re:.NET 6 Preview 5 by EvilEy3 on Friday June 18, 2021 @05:06PM (#27555053)
> your average .net dev gets paid less than your average COBOL dev too

I don't see how this is a valid comparison. Java being paid better has nothing to do with scarcity of expertise.

Re:.NET 6 Preview 5 by aksss on Friday June 18, 2021 @06:25PM (#27555661)
The comparison was to illustrate that scarcity of expertise absolutely affects pay rate, notwithstanding other explanations.

Whether that explains part or most or all of Java dev pay premium is at least debatable. For instance, I would never make the same "throw a rock into a crowd" statement about finding a competent (but not expert) java developer. That alone means I would expect to pay some of a premium for finding them in that crowd.

What's the counter argument to scarcity? Alignment with better paying industries, weighted so heavily in that direction that it shows up as a premium for their developers? I mean, if you start getting into the conversations about the obscurity of domains, or supplemental education associated with Java developers either by coincidence or requirement, or general demand, I think you're still commenting about scarcity.

Re:.NET 6 Preview 5 by xtracto on Friday June 18, 2021 @02:34PM (#27553406)
I programmed professionally in .NET around 2003 with the initial versions. I liked it a lot and over the next years I tried to keep up to date about it on my spare time (I remember reading about LINQ development, the amazing CLR improvements, etc), all while I developed in Java, ruby and nowadays TypeScript.

The problem I see with .NET now (I did some tinkering on it via Unity) is that even though some of it is "open source", Micorsoft's grip is still pretty tight on it. Or at least it feels like that.

Given Microsoft's history I find it very difficult to "commit" to using the .NET framework for something real, because I feel I will be bitten back with the 'proprietary' aspects of it as soon as I go to production. It's a sunk cost that I cannot afford.

And it is not personal 'hatred' or anything given that I use VSCode as an editor and TypeScript itself comes from Microsoft.

I wish Microsoft would donate .NET to some 3rd party open source foundation (like what happens with all Apache projects, or LibreOffice, the MariaDB foundation, etc).

Re:.NET 6 Preview 5 by oaiey on Friday June 18, 2021 @03:08PM (#27553766)
Modern .NET is legally owned by the .NET Foundation. It is MIT/Apache licensed with the exception of some debuggers in VS Code (which propably conflict with VS itself).

Granted, the .NET Foundation is not the Apache, Eclipse, Linux or CNCF Foundation and it is dominantly financed by Microsoft, but there are relative important peers like AWS or RedHat involved.

Re:.NET 6 Preview 5 by hu3 on Friday June 18, 2021 @05:04PM (#27555038)
Plus now we have Jetbrains Rider. So there's an excellent non-Microsoft IDE alternative.
Re:.NET 6 Preview 5 by gtsteve on Friday June 18, 2021 @06:36PM (#27555758)
Rider is no joke. If you haven't used it or gave up on it a few years back, give it a shot. There are a few things it can't do like attach to managed modules hosted in unmanaged processes but it's a joy to code in.