3 ms·
Completely agree, except that MS was so crazy hostile to OSS that they scared off all the serious guys a decade ago. I wish them the best. The CLR has some comp
by spricket 8y ago
Completely agree, except that MS was so crazy hostile to OSS that they scared off all the serious guys a decade ago. I wish them the best. The CLR has some compelling features that make it objectively better than JVM on so many levels.
But the lack of ecosystem is killing them. And has been forever. The new MS CEO is great in my mind but it will take many years to turn the ship around. Devs don't forget.
Best example I can think of (was a C# guy for years). Resharper has been around forever. But it costs a lot. This is par the course for C#. I can get the same thing in Java by pulling in a few linters with Maven, and it's all free. Because MS scared away everyone that was afraid of licensing fees (ie most academics, the sharpest devs out there), there's nothing comparable.
Same with C# port of Quartz and so many others. They killed off the real rockstars among us that create the majority of libraries that everyone else uses.
Can it be fixed? I hope so. The CLR is great and Oracle sucks. But for now there's a good reason Java is dominant
- scarface74 8y agoResharper is $139 a year for a personal license and the price goes down 20% after the first year and 40% year after that. You can also pay monthly. They also have a perpetual license. If you cancel after the first year, you can keep using the version that was current 12 months ago. But the one thing missing in Java is anything like LINQ. I don’t mean the syntax I am referring to the idea of LINQ -> expression trees -> third party providers that translate LINQ to another language (sql, Mongo Query, etc.).
- spricket 8y agoIt's not built in to the language, but JOOQ and QueryDSL come fairly close. I do miss LINQ though. The Java options are all clunkier because the type system isn't nearly as flexible
- scarface74 8y agoI can't tell from looking at the examples, but can I do things like pass around arbitrary expressions: Person.Get(p => (p.Age > 65 && p.Sex == "M") || (p.Age > 63 && p.Sex == "F")) and have a method public List<Person> Get(Expression<Func<Person,bool>> expression) and have that expression interpreted correctly at run time by separate providers? You get full compile time checking and IDE supported autocomplete.
- spricket 8y agoYes. But it's done in a different way than C#. C# supports fields and field references so you can pass them directly to a function. The Java code "looks" like they do the same because they generate code to simulate method references instead. It's pretty clever and Javas code generation support for Annotation Processors is excellent and makes it possible to do this in a cross-ide cross-build-system way LINQ and JOOQ/QueryDSL all work on plain data objects with fields. But with Java you do it on a pseudo object generated from your existing classes
- scarface74 8y agoThat's really interesting. All of these years I've been beating up on Java for lack of something akin to LINQ. I guess I'll have to find something else to complain about.....
- spricket 8y agoIMO LINQ is still better because of how integrated into the language it is. JOOQ and QueryDSL were basically designed to replicate it as much as possible but not nearly to convenience levels of LINQ + Entity Framework