News for hackers. Stuff that matters.
Re:Microsoft's “Love” of Linux by stevbov on Thursday November 21, 2019 @11:10AM (#21595631)
Why would any Linux shop use SQL Server anyways? Why would they use .NET Core? The only people I know pushing .NET Core are .NET people, not Linux people. My general rule is to never use a technology where your primary platform is a second class citizen. It just makes things a pain: not only could support be dropped in the future because there's no profit in it, its also harder to find answers to problems on the internet.
Re:Microsoft's “Love” of Linux by lghh on Thursday November 21, 2019 @11:13AM (#21595662)
I'm a Linux person who likes .NET Core. I like C# quite a bit, and I don't think Linux is a 2nd class citizen for .NET Core.
Re:Microsoft's “Love” of Linux by merb on Thursday November 21, 2019 @11:27AM (#21595838)
especially since kestrel is faster on linux than on windows. (well it's slower than iis inProcess, but still)
Re:Microsoft's “Love” of Linux by ripley12 on Thursday November 21, 2019 @11:34AM (#21595916)
It is still a 2nd class citizen, IMO – but I think that's improving rapidly. Some examples:

-IDE support from MS is markedly better on Windows (real Visual Studio) and Mac (VS for Mac). VS Code+Omnisharp is still pretty rough around the edges for C#.

-Many of the older .NET class libraries were just not designed with *nix in mind. System.IO still doesn't support symlinks https://github.com/dotnet/corefx/issues/26310

Re:Microsoft's “Love” of Linux by zamalek on Thursday November 21, 2019 @12:02PM (#21596300)
> Many of the older .NET class libraries were just not designed with *nix in mind. System.IO still doesn't support symlinks

Windows supports symlinks, so that problem is not unique to netcore on nix. Many of the newer APIs are designed with explicit support for nix.

Re:Microsoft's “Love” of Linux by ripley12 on Thursday November 21, 2019 @12:26PM (#21596683)
Yup, but I think the problem stems from symlinks being relatively uncommon in NTFS compared to nix filesystems - it just wasn't a priority for the original .NET designers who were mostly targeting Windows. https://blogs.windows.com/windowsdeveloper/2016/12/02/symlin...
Re:Microsoft's “Love” of Linux by garganzol on Thursday November 21, 2019 @12:04PM (#21596341)
Sometimes I think that Linux is the 1st class citizen for .NET Core when it comes to a server stack. .NET Core is seriously awesome since version 2.0 on all platforms.
Re:Microsoft's “Love” of Linux by dpark on Thursday November 21, 2019 @11:16AM (#21595711)
> The only people I know pushing .NET Core are .NET people

Isn’t someone pushing .Net by definition a .Net person?

Re:Microsoft's “Love” of Linux by scarface74 on Thursday November 21, 2019 @11:12AM (#21595657)
How is Linux a second class citizen for .Net Core?

Have you ever had a problem with .Net Core on Linux that you couldn't find an answer to?

Re:Microsoft's “Love” of Linux by tracker1 on Thursday November 21, 2019 @12:19PM (#21596581)
I've actually had more issues with it in Windows than on Linux/Mac. Though I will say VS proper is much nicer than VS Code for C# development. It will improve. I'd still prefer to use mostly node, which gets its' own ire from the developer community.
Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @04:41PM (#21599985)
- dotnet-cli will try to cache a bunch of junk into its install folder, rather than respecting $XDG_CACHE_HOME, or even just using a plain old dotfile. These days it just generates an annoying warning on each run, but it used to be a hard error.

- OmniSharp just plain doesn't work on NixOS, because it hardcodes a bunch of Ubuntu paths.

- It seems to support automatically switching between multiple SDK versions, but I've never been able to get that to work.

Re:Microsoft's “Love” of Linux by autechr3 on Thursday November 21, 2019 @12:00PM (#21596277)
We are about to launch a new .NET core service and I've been working with .NET core for about 2 years now. Not only is Linux not a second class citizen (it is the easiest platform to run on and scale), but dropping support would make no sense from a business or technical standpoint. Microsoft is making a ton of money by supporting cross platform.

We aren't using SQL Server, but I've used most of the big RDBMS and SQL Server is the best. It just tends to be more expensive.

So far it has been anything but a "pain".

Re:Microsoft's “Love” of Linux by Foobar8568 on Thursday November 21, 2019 @11:42AM (#21596008)
Because Microsoft makes some of the best tools for developers.

Because sql server is a fantastic product that has basically no real equivalent on the market.

And funnily enough, I always feel that .Net core primary platform was Linux and not windows. Same for visual studio code, and I wouldn't be surprised if in a few years, new sql server features won't appear first on the Linux version. And actually it's somewhat the case with sql server big data cluster.

Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @11:55AM (#21596198)
> Because Microsoft makes some of the best tools for developers.

NuGet constantly fails silently when trying to restore packages.

Visual Studio is an editor built primarily around a folder tree, with no competent way to navigate that tree without constantly losing your place. It's also the only IDE that I have used where I just had to give up trying to find the application logs.

> Because sql server is a fantastic product that has basically no real equivalent on the market.

MSSQL's utter incompetence makes MySQL's `utf8` troubles look like small potatoes. For example: the `uniqueidentifier` type doesn't have a defined endianness, meaning that there is no guarantee that two languages reading the same cell will produce the same UUID string.

SSMS is an unusable hog. There is just no nice way to put it.

SQLCMD must have been designed by people who have never actually used a CLI.

Re:Microsoft's “Love” of Linux by fhery on Thursday November 21, 2019 @01:57PM (#21597947)
Wow, you must've been trying hard to cherry pick those.

I'm actually curious about this one:

>SSMS is an unusable hog. There is just no nice way to put it.

I've been using both postgre and sql server for like 1.5 year and tooling difference between pgAdmin and SSMS is insane

SSMS is mature, reliable and makes my life easier meanwhile pgAdmin is just viable, but nothing more.

Generally SQL Server seems to be years ahead in compare to postgre when it comes to features/tooling.

I also used mysql via xamp and sql management in compare to all of those is world class

>NuGet constantly fails silently when trying to restore packages.

what?

Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @03:14PM (#21599008)
> Wow, you must've been trying hard to cherry pick those.

Not really. Just try keeping a .NET/MSSQL environment running for a few days, and the stories will build up quickly.

> SSMS is mature, reliable and makes my life easier meanwhile pgAdmin is just viable, but nothing more.

But psql is good enough that I pretty much never have to touch pgAdmin. And for ad-hoc editing (the only case where graphical editors have any real advantage), surprise, SSMS can't edit the results of custom queries. pgAdmin doesn't care, as long as the query contains the primary key.

And there is also a lot of polish that SSMS just doesn't have. Like how it forgets the order of your tabs as soon as they overflow. Or how you can't just do an ad-hoc query and see the result, you need to open a new query "document".

>> NuGet constantly fails silently when trying to restore packages.

> what?

That was my reaction too. Sometimes it decides that it won't build at all because it complains about unresolved references. Sometimes it builds but assets will be missing. And of course it's an opaque black box in the usual MS fashion, so there is no way to force it to retry, or to find out why it's not cooperating.

Re:Microsoft's “Love” of Linux by fhery on Thursday November 21, 2019 @06:47PM (#21601034)
What about copying data between databases? I couldnt get it right in pg, meanwhile works fine in SQL Server

Also pgAdmin has no(?) Intellisense.

Re:Microsoft's “Love” of Linux by Nullabillity on Friday November 22, 2019 @01:10AM (#21603220)
> What about copying data between databases? I couldnt get it right in pg, meanwhile works fine in SQL Server

Export to SQL with pg_dump[0], or export to CSV with COPY[1] or \copy[2].

> Also pgAdmin has no(?) Intellisense.

Press ctrl+space for auto-complete. It also seems to pop up when you press `.` (in a valid place).

psql follows the more typical convention of auto-completing on tab.

[0]: https://www.postgresql.org/docs/12/app-pgdump.html

[1]: https://www.postgresql.org/docs/current/sql-copy.html

[2]: https://www.postgresql.org/docs/current/app-psql.html#APP-PS...

Re:Microsoft's “Love” of Linux by juststeve on Thursday November 21, 2019 @02:41PM (#21598576)
When you type Install-Package in Visual Studio, sometimes it just fails to find the package at all. You have to search for it first, then type Install-Package, and then it actually downloads etc.
Re:Microsoft's “Love” of Linux by fhery on Thursday November 21, 2019 @06:49PM (#21601049)
I'm always doing it via Nuget Package Manager and I don't remember having any troubles with that

I'm using dotnet's CLI mostly for migrations/publishing

Re:Microsoft's “Love” of Linux by juststeve on Friday November 22, 2019 @03:47AM (#21603930)
Yeah i think package manager GUI is ok? but cli and powershell, not so much
Re:Microsoft's “Love” of Linux by ripley12 on Thursday November 21, 2019 @12:58PM (#21597149)
> SSMS is an unusable hog.

...huh? SSMS (plus the free Red Gate SQL Search addin) is hands-down the best DB tooling I've ever used. If you're aware of similarly full-featured equivalents for Postgres (or any other RDBMS), I'd love to hear about them.

Re:Microsoft's “Love” of Linux by keithnz on Thursday November 21, 2019 @07:36PM (#21601335)
have you tried DataGrip? I went from SSMS to DataGrip for most of my database work. SSMS is still better for management of the SQL Server instance, but for database work, DataGrip is a lot nicer than SSMS (and SSMS is a lot nicer than a LOT of other tools for other RDBMSs)
Re:Microsoft's “Love” of Linux by ripley12 on Sunday November 24, 2019 @11:39AM (#21621477)
Interesting, thanks!

I have tried DataGrip briefly with Postgres – my first impression was that it's a competent tool for things that are generic across all RDBMSs, but limited in RDBMS-specific management/administration functionality. Not far off from what you said :)

If you have time, what about DataGrip do you find to be "a lot nicer than SSMS"? Which features should I (a DataGrip noob) try using?

Re:Microsoft's “Love” of Linux by keithnz on Sunday November 24, 2019 @04:10PM (#21623438)
First of all, I don't think I've personally scratched the surface of what you can do. But I use it mostly as a direct replacement of what I would have done in SSMS.

First of all Start writing queries and see how much it will help you, for the most it will autocomplete lots of things, once you are used to joins been auto written for you, hard to go back!

personal preference, but, it supports vim bindings.

Its table editor works on partial queries for updates, so you can select something and as long as you selected the key, you can do a update using the table editor. Speaking of the table editor, it is vastly superior and allows batching of changes, it shows you queries its going to do, has lots of helpers for all sorts of things including datetimes. It has lots of options to capture the table in lots of formats. It also allows across database comparisons of tables and synchronization or generation of sql scripts of differences/database changes.

Its ide is standard jetbrains ide ish and has lots editing goodness, refactoring, auto generation, surrounds, templates, local change history, lots of navigation tools ( go to references / usages etc )

Re:Microsoft's “Love” of Linux by excursionist on Thursday November 21, 2019 @11:53AM (#21596174)
> Because Microsoft makes some of the best tools for developers.

What are some of these tools besides VSCode, and what makes them 'the best'?

> Because sql server is a fantastic product that has basically no real equivalent on the market.

What makes SQL Server so much better than, say, PostgreSQL or MariaDB?

> And funnily enough, I always feel that .Net core primary platform was Linux and not windows.

Why?

Re:Microsoft's “Love” of Linux by ripley12 on Thursday November 21, 2019 @01:01PM (#21597198)
> What makes SQL Server so much better than, say, PostgreSQL or MariaDB?

Tooling and speed. I can vouch for the quality of SQL Server's tooling – SSMS is very nicely integrated with SQL Server.

If you watch the CMU DB Group's lectures on YouTube, they mention that the commercial RDBMSs have put a lot more time+research into query optimization than the open source ones (and apparently SQL Server has the best optimizer).

Re:Microsoft's “Love” of Linux by excursionist on Thursday November 21, 2019 @01:18PM (#21597402)
> Tooling and speed.

That's too vague to be of any use. What tooling? What benchmarks?

> I can vouch for the quality of SQL Server's tooling – SSMS is very nicely integrated with SQL Server.

The fact that you like SSMS doesn't really say anything about tooling for PostgreSQL. I find the quality of PostgreSQL tooling great.

There is certainly plenty of reason to believe PostgreSQL is superior to MS SQL [1]. I don't agree with everything in the referenced article, but your claim of MS SQL being far superior is, so far, completely unsubstantiated.

[1] https://www.pg-versus-ms.com/

Re:Microsoft's “Love” of Linux by ripley12 on Thursday November 21, 2019 @05:00PM (#21600169)
You’re a little combative, huh?

As I’m sure you’re aware, publishing benchmarks of commercial RDBMSs is usually prohibited - I’m just passing on what I’ve heard from an expert about query optimizers.

Re:Microsoft's “Love” of Linux by excursionist on Friday November 22, 2019 @11:32AM (#21607110)
> You’re a little combative, huh?

Interpreting the questioning of your grand claims as combative should tell you something about your own attitude.

> As I’m sure you’re aware, publishing benchmarks of commercial RDBMSs is usually prohibited

I only know that MS and Oracle prohibit publishing such benchmarks - and that's yet another reason not to use them.

Re:Microsoft's “Love” of Linux by fhery on Thursday November 21, 2019 @02:04PM (#21598043)
>What makes SQL Server so much better than, say, PostgreSQL or MariaDB?

Tooling

Re:Microsoft's “Love” of Linux by Quarrelsome on Thursday November 21, 2019 @11:46AM (#21596061)
isn't Postgres an equivalent?
Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @11:56AM (#21596204)
Not really, Postgres actually works.
Re:Microsoft's “Love” of Linux by tracker1 on Thursday November 21, 2019 @12:20PM (#21596599)
Except for in-the-box replication and failover options.
Re:Microsoft's “Love” of Linux by antod on Thursday November 21, 2019 @01:41PM (#21597716)
"in-the-box" unless you're using the "cheaper" licence options. (possibly out of date opinion)
Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @12:30PM (#21596745)
MSSQL's replication is a minefield of ways to screw it up completely.
Re:Microsoft's “Love” of Linux by tracker1 on Thursday November 21, 2019 @01:41PM (#21597725)
Not that I disagree... but by comparison, PosgreSQL replication would be a minefield of nuclear bombs without a map.
Re:Microsoft's “Love” of Linux by Nullabillity on Thursday November 21, 2019 @03:31PM (#21599247)
Not using it for anything super critical yet, but Patroni is pretty much plug-and-play, and becomes transparent to the client once set up. No need to worry about whether your client supports MultiSubnetFailover, or whether you remembered to copy your users manually.
Re:Microsoft's “Love” of Linux by wvenable on Thursday November 21, 2019 @01:20PM (#21597427)
> The only people I know pushing .NET Core are .NET people, not Linux people.

Miguel de Icaza would probably have an issue with that statement.

Re:Microsoft's “Love” of Linux by eternalny1 on Thursday November 21, 2019 @11:28AM (#21595843)
Our Angular web app runs .Net Core on Linux.

.Net Core is fantastic, C# is a great language, I don't see any downsides with our stack.

Re:Microsoft's “Love” of Linux by tracker1 on Thursday November 21, 2019 @12:23PM (#21596654)
Biggest down side for me, is .Net Core 3 had some dramatic breaks, it's better than 2 and before, but still been burdensome.

There's two decades of answers and examples out there, many of which don't work. Not to mention many third party libraries that do stuff that's now in the box.

Biggest gripe to me, is lack of in the box support for PEM files in the crypto library. There are others, Core 3 breaks DI for logging in the Startup is another big one.

In the end, it's decent... I'd still largely rather use Node, or if I need more performance Rust of even Go. I will say I don't hate it, it's just frustrating finding examples and answers.

Re:Microsoft's “Love” of Linux by ClumsyPilot on Thursday November 21, 2019 @02:16PM (#21598220)
Every language and framework has it warts, and the ones in JS/Node could fill a library.

You pick your poison.

Re:Microsoft's “Love” of Linux by tracker1 on Saturday November 23, 2019 @10:32PM (#21618166)
Not disagreeing on JS/Node... I will say I get so much better velocity in terms of practical work done with my time. But I've also seen people do some goofy things in JS, but will counter that most people are snooty about it and don't bother actually learning the language, reminds me a lot of VB a couple decades ago (the culture against it).