by eksemplar · 7y ago · 0 comments
We’ve been a C# house for several years, decades really, and I’ve always preferred it to JAVA so I’m actually excited for Core.
But we rarely use it. Not because it’s not great, rather because we’re more productive with flask or Django. For Core to really make sense for us, it’d would have to stop being so damn low level, but I guess that maybe it can’t without sacrificing too much efficiency. More importantly it needs better libraries for things that aren’t “built-in”.
I can certainly see why .NET developers welcome it, because they finally have good cross platform ability. At least until they need to do authentication on a non-standard SAML token, that though easily supported by ADFS but is a bitch in any .NET setup.
I know we aren’t most use cases, being the public sector and running a gazillion different tech stacks at once, but .NET has never played well once you stepped outside it’s comfortzone and it’s always been so low level that writing library extensions were a bitch. And that may have worked out, so far, but I just don’t see why people stick with it when there are more productive alternatives.
I say productive, because I don’t think .NET core is lacking technically, but delivering solutions on time and with minimum maintenance requirements afterward is just easier in python or JAVA and I’d imagine others as well.
But maybe I’m missing something?
> but delivering solutions on time and with minimum maintenance requirements afterward is just easier in python or JAVA
I would agree if you would replace Python/Java with Node, but with these languages I don't see it.
> on time and with minimum maintenance requirements afterward
This is my Dockerfile, it is serving me without changes (technically replacing 2.1 with 2.2 is a change) for more than 6 months.
# Build assets
FROM node:8-alpine AS assets
WORKDIR /app
COPY src/Website/Package.json ./Website/package.json
COPY src/Website/Gulpfile.js ./Website/
COPY src/Website/Static/. ./Website/Static
WORKDIR /app/Website
RUN npm install
RUN npm run build
# Build project
FROM microsoft/dotnet:2.2-sdk-alpine AS build
WORKDIR /app
COPY src/Website/*.csproj ./Website/
WORKDIR /app/Website
RUN dotnet restore
WORKDIR /app
COPY src/Website/. ./Website/
WORKDIR /app/Website
RUN dotnet publish -c Release -o dist
# Run project
FROM microsoft/dotnet:2.2-aspnetcore-runtime-alpine AS runtime
WORKDIR /app
COPY --from=build /app/Website/dist ./
COPY --from=assets /app/Website/Static/dist ./Static/dist
RUN rm /app/Data/Log/.gitkeep
ENTRYPOINT ["dotnet", "Website.dll"]
>But maybe I’m missing something?I think you might be.
.NET is an ecosystem of languages, runtimes, and tooling with Visual Studio being regarded by many as the best IDE. Add in the vast MS suite of Windows, Office, Azure, SQL Server, and the rest and you have one of the most productive frameworks to build anything for desktop, mobile, games, server backends, and even databases.
We moved over to .NET Core since v1.0 to consolidate on Linux/K8S and it's been a great experience. ASP.NET Core is also a very good framework for building webapps, SPAs and APIs that has more functionality in the box than pretty much anything else we've seen.
Nuget is turning into a solid package management system and there are great 3rd-party projects like IdentityServer for authentication, have you looked at that?
Could you please expand on this one?
I can however offer a simple possible explanation for your experience: you are more proficient in other languages and frameworks because you know them better.
Yet another case of “Do people still watch TV? I haven’t owned a TV in 10 years”, style myopia.
By the time we have an app running in Django, we’re not even finished with Entity modelling in a Core web-api.
I do think stuff like Blazor.Net is promising, but we’re not a technology company, we support thousands of employees who only care about how digitisation can make their lives easier as fast and as stable as possible.
.NET isn’t the best at that, at least not for us.
Dont get me wrong, I don’t dislike .NET Core, it think it’s great, I just don’t see how it benefits me.
>.NET isn’t the best at that, at least not for us.
You're comparing apples and oranges, djanjo is a web framework, for creating websites, .Net core is a cross platform compiler and the standard library that goes with the C# programming language, which includes some stuff for creating websites (along with desktop, CLI, services etc). Django might work best for you but I want to create a bunch of micro services I'm not going to use it, am I? Not to mention Django works well as a general purpose solution for general purpose websites, If you're building anysort of heavyweight, enterprises level web architecture you're going to want a hell of a lot more control that what django provides for you.
Obviously we don’t use Django for everything. But like with web-applications, a python script or a flask application is always more productive for us than .NET.
I find I'm most productive in C#, but probably mostly because it's what I use every day and I like the tooling.
I have been developing in C# for years and I still prefer Python's simplicity over C# and .NET. C# and .NET just seems to have too many concepts, indirection, and 'enterpriseyness' for my liking. This is alleviated by things like LINQ, but still an issue for me.
Plus you get a decent static type system!