Roundup #11: Solution-wide NuGet packages, REST vs. GraphQL, The Power of Roslyn, Blazor 0.5.0

Here are the things that caught my eye this week.  I’d love to hear what you found most interesting this week.  Let me know in the comments or on Twitter.

Solution-wide Nuget package version handling with MsBuild 15+

In order to centrally manage package versions, you can now leverage the Directory.Build.targets feature. Without going into too much detail (the linked document explains it well), Directory.Build.targets can be used to provide customizations to project files located under a certain directory (within a directory tree).

I remember seeing this from David Kean several months back on Twitter.  This is incredibly useful for keeping versions of packages consistent across projects.

Link: https://www.strathweb.com/2018/07/solution-wide-nuget-package-version-handling-with-msbuild-15/

 

REST vs. GraphQL: A Critical Review

Here is the idea: If you have never heard about the REST architectural style constraints and their implication on the properties of the resulting distributed system and you do not want to (or can’t) educate yourself, use GraphQL.

With all the buzz on Twitter about REST and GraphQL, I figured I’d toss this post in the mix.  Worth reading the comments as well to get a bigger picture.  Seems like people either sit in the REST (not CRUD but with Hypermedia) or the GraphQL camp, and nowhere in between.

Link: https://blog.goodapi.co/rest-vs-graphql-a-critical-review-5f77392658e7

 

The Power of Roslyn – Kasey Uhlenhuth

Four years ago we open sourced the C# and Visual Basic compilers and exposed their functionality through APIs as the Roslyn project. The Roslyn analyzer API empowers the developer community to be more productive by lighting up their own features in the editor in real-time–meaning anyone can write a refactoring, code fix, code style rule, or code diagnostic.

Come learn more about the Roslyn project, new APIs we’re adding, and what these live analyzers mean for you and your productivity.

I’ve always been interested in writing an Roslyn Analyzer but just wasn’t really sure where or how to get started.  If you feel the same, I recommend checking out this talk.

Link: https://www.youtube.com/watch?v=nXljhGDokqA

 

Blazor 0.5.0

Blazor 0.5.0 is now available! This release explores scenarios where Blazor is run in a separate process from the rendering process. Specifically, Blazor 0.5.0 enables the option to run Blazor on the server and then handle all UI interactions over a SignalR connection. This release also adds some very early support for debugging your Blazor .NET code in the browser!

Pretty interesting to see the updates to the JavaScript interop.  I felt like in previous versions this was the most awkward part of Blazor.

Link: https://blogs.msdn.microsoft.com/webdev/2018/07/25/blazor-0-5-0-experimental-release-now-available/

 

Enjoy this post? Subscribe!

Subscribe to our weekly Newsletter and stay tuned.

Roundup #10: Octopus + Containers, Converting web.config to JSON, .NET’s Memory Management

Here are the things that caught my eye this week.  I’d love to hear what you found most interesting this week.  Let me know in the comments or on Twitter.

Kubernetes, Containers, and Octopus – An Update

A few months back we asked the Octopus community if they could spare a few minutes and brain-cycles to provide some feedback on the first-draft of our Kubernetes plans. And you certainly delivered. So first, thank-you! We sincerely appreciate everyone who shared their thoughts. The product will certainly benefit from it.

This is pretty interesting as I’ve always really loved Octopus but felt it a bit out of place for dealing with container images.   They are hitting the nail right on the head with point #3 on something similar that I’ve done.

Customers are even simulating these by including dummy packages (e.g. NuGet or Zip) in their deployment process to represent their container images, since these would be captured in the release. This is very clever, but also made us sad. It shouldn’t require that level of ingenuity.

Link: https://octopus.com/blog/kubernetes-containers-update

 

Converting web.config files to appsettings.json with a .NET Core global tool

In this post I describe how and why I created a .NET Core global tool to easily convert configuration stored in web.config files to the JSON format more commonly used for configuration in ASP.NET Core.

Really helpful post if you’re migrating from an web.config to asp.net core and want to transition to json config.

Link: https://andrewlock.net/converting-web-config-files-to-appsettings-json-with-a-net-core-global-tool/

 

Exploring NET’s Memory Management — A Trip Down Memory Lane

I was recently speaking with someone regarding the .NET GC and memory and immediately thought of this talk.   Highly recommend checking it out if you are unfamiliar with how the GC works and when memory is allocated in .NET.

The .NET Garbage Collector (GC) is really cool. It helps providing our applications with virtually unlimited memory, so we can focus on writing code instead of manually freeing up memory. But how does .NET manage that memory? What are hidden allocations? Are strings evil? It still matters to understand when and where memory is allocated.

In this talk, we go over the base concepts of .NET memory management and explore how .NET helps us and how we can help .NET – making our apps better. Expect profiling, Intermediate Language (IL), and using ClrMD to mimic some inspections dotMemory provides.

Link: https://www.youtube.com/watch?v=9FEfy9y0fFQ

 

Enjoy this post? Subscribe!

Subscribe to our weekly Newsletter and stay tuned.

Roundup #9: Razor Email Templates, AWS Lamba .NET Core 2.1, Contract First API Design with OpenAPI V3

Here are the things that caught my eye this week.  I’d love to hear what you found most interesting this week.  Let me know in the comments or on Twitter.

Walkthrough: Creating an HTML Email Template with Razor and Razor Class Libraries and Rendering it from a .NET Standard Class Library

HTML emails are the absolute worst.  Inlined styles.  Nested tables.  Different apps and platforms render the markup differently.  It’s an absolute train wreck.  However, sending plain text emails isn’t a great way to impress your users and often makes emails look fake or like spam.  So fine, HTML emails.  Let’s do it.

Link: https://scottsauber.com/2018/07/07/walkthrough-creating-an-html-email-template-with-razor-and-razor-class-libraries-and-rendering-it-from-a-net-standard-class-library/

 

AWS Lambda Supports .NET Core 2.1

You can now develop your AWS Lambda function code in C# using the .NET Core 2.1 runtime which will soon be the Long Term Support (LTS) version of .NET Core.

Link: https://aws.amazon.com/about-aws/whats-new/2018/06/lambda-supports-dotnetcore-twopointone/

 

Contract First API Design with OpenAPI V3 – Darrel Miller

The Swagger specification is all grown up with it’s new enterprisey name, OpenAPI and there’s a whole set of new features in V3, like links and callbacks. This session will explore what’s new in OpenAPI V3 while designing and building an HTTP API.

Most Swagger/OpenAPI users started by generating their OpenAPI from an API implementation. As developers gain experience, many start to change their approach to start with an OpenAPI description and build an implementation from that. We will compare the approaches and talk about the advantages of Contract First with OpenAPI.

Link: https://www.youtube.com/watch?v=GtTiIY51kK0

 

Enjoy this post? Subscribe!

Subscribe to our weekly Newsletter and stay tuned.