The Core of .NET

VSW08 High Performance JSON Serialization with Code Generation on C# 10 and .NET 6.0 in Modern .NET Applications

11/16/2022

2:00pm - 3:15pm

Level: Advanced

Ian Griffiths

Technical Fellow

endjin

In this talk, you will see how features added to recent versions of C# can dramatically improve parsing and generation of JSON data compared with longer established .NET JSON handling mechanisms. You will see how to use high-performance memory-efficient techniques (including Spans and IO Pipelines), and also how code generators can reduce runtime overheads. This talk will explore the tradeoff between maximizing performance and ease of use, and will show how choose between the various options now available in modern .NET applications.

You will learn:

  • Understand how recent C# features can improve serialization performance
  • Understand the trade-offs between .NET's various JSON serialization models
  • Understand how both built-in and custom code generators can help enhance performance