Speaker

Zoran Horvat

Zoran Horvat

Principal consultant at Coding Helmet s.p.r.l.

Belgrade, Serbia

Zoran is a principal consultant at Coding Helmet Consultancy, an author at Pluralsight, Udemy, and YouTube, a speaker and author of 100+ articles, and an independent trainer on the .NET technology stack. You can find him speaking at conferences and user groups, promoting object-oriented and functional development styles, clean coding practices, and techniques that improve the longevity of complex business applications.

Area of Expertise

  • Information & Communications Technology

Topics

  • Architecture
  • OOP
  • functional programming
  • Programming
  • Azure
  • .NET
  • C#.Net

Functional Thinking with C# 11: The Missing Parts

Functional programming had crossed paths with C# years ago, adding a lot to the language's specification. We have functional sequences with LINQ, built on top of list comprehension. There are lambdas and closures, support for tuples, records, and pattern matching. We can build our own functional extensions. Yet, some crucial parts are still missing. Common functional types, such as Option and Either are not available and there is no supporting syntax. Discriminated unions are still but a distant dream.
In this presentation, you will learn how you can build your own substitutes for the missing concepts without having to step back to the traditional imperative coding style. The goal of the game: Stay within C#, keep thinking functionally, and don't worry too much about missing types or syntax.

This talk was presented at conferences a few years back. The current state of this talk is mostly the evolution of introductory demos available on my YouTube channel: https://www.youtube.com/playlist?list=PLSDYwLgFqaX78eEg_YKs0wHmOMi7_ggZr

Brave New Nullless World in C# 11

Beyond nullable (I mean: non-nullable) reference types, null coalescing and null propagation operators in C#, closing the outer door for nulls in only the first step in securing your models from missing and nonexistent objects. A much larger work is only to begin, and that is to develop a proper object model which never issues a null, nor ever fails due to receiving one from the outside.
In this session, we will outline the place for the null-related C# syntax in domain modeling. Then, we will revisit often overlooked patterns: polymorphic models and optional objects. With these tools put together and enforced with latest language syntax, you will never want to return to using null references.

This talk was presented in several forms since 2017. The last presentation was at the Update Conference Prague, in November 2022 (https://www.updateconference.net/en/2022/schedule).
The content was evolving as the language was evolving. By the time of the conference, the materials will be fully compliant with .NET 7 and C# 11, demonstrating the latest pieces of syntax in the light of suppressing nulls.

So, you're writing code one line at a time? Yeah, right!

Iterative development is one of those agile techniques that so often turn into their opposite: blinded by the very iterations, developers cannot see the upfront design they are implicitly following. Isn’t there anything we can do to improve iterative development?
In this demonstration, you will see how code can grow one line at a time, literally, and yet every next line will add one complete, and often final, feature to the design. And with every new feature added, we will still retain a good design – the one with responsibilities separated, components loosely coupled, with good naming and other qualities we prefer.

This talk was first presented in 2018. The recording is available:
https://www.youtube.com/watch?v=Z6hQz81ex6U&ab_channel=ZoranHorvat
The current version of this talk features the latest C# 11 syntax and a bit cleaner example.
Of all the talks I have prepared in the last decade, this one is my favorite. The audience always enjoys the kind of evolution of code demonstrated.

There and Back Again of Software Architecture: Monoliths vs. Microservices

Any mention of monolithic applications would raise an eyebrow or two today - and with a good reason. Our accumulated experience is teaching us that monolithic applications bring many issues, not least important them being hard to maintain. On the other end of the specter we find microservices, the preferred design in the eyes of many. And there are myriads of designs and architectures in between these two extremes. Who's right there?
In this presentation, we will analyze common design problems, starting from monolithic designs, paying extra attention to pathological coupling, violating transactional consistency and unclear data ownership.
By the end of this presentation, you will learn that, from perspective of design, there is no substantial difference between multitier design which resembles a monolith and microservices - assuming each of them is done right. And more, you will learn that a proper, maintainable monolith can easily be morphed into microservices, and vice versa.

This talk was presented several times so far at conferences over the years and its content has evolved to follow the trends (or: anti-trends that the talk is addressing!) as they happened. The talk is available in 40-, 60-, and 90-minute versions.
The latest edition of this talk is included in the SDD London conference in May 2023 as a 90-minute talk.

Speak the Language - The Domain Language!

To develop software is to write code. Yet, code is not software. There is more in it than just code: There is structure; there are protocols; there are loads and volumes. And yet, even there, one vital ingredient is missing.
Through a series of illustrative code samples, you will learn that developing software is more about speaking the language than about any of its technical aspects. Your code will be a software if it speaks the language of the business it is modeling - that is the thesis we will try to outline in this talk.

This talk was presented several times, the first time during the 2020 lockdown.
The last presentation was at Banja Luka DevHosted conference, Bosnia and Herzegovina, in October 2023.

Software Is Not a Very Fast Pencil

In this talk, we will outline one common fallacy in software development. It comes from inability to view software as a tool that operates on a different plane compared to traditional pen-and-paper business. In a typical scenario, customer would look for software as a replacement to traditional business, effectively robbing their business of the opportunity to transform into pure digital form. In this talk, we will explain how that fallacy happens, why development teams fail to notice it, and - most valuable - how that tragic error can be avoided in real software development. By the end of the demonstration, you will view software with different eyes: As a unique take on the business problem, rather than a rework of any existing practices.

This talk was presented at Pluralsight Live, in October 2020. The recording is only available with a subscription to pluralsight.com.
That talk was 100% slides, but my plan is to add a working demo for the next opportunity to present.
There is a textual version explaining the topic of this talk: https://codinghelmet.com/articles/the-fast-pencil-fallacy-in-software-development

Functional Domain Modeling in C# Using the Latest Language Features

Mixing functional programming and metaprogramming into good-old object-oriented C# is not new. Still, so many programmers don't see it clearly yet: Those paradigms are not additions to an established programming model; they are genuine parts of a unified programming method, support for which is progressively being added to the C# programming language.
In this session, we will demonstrate the use of the latest functional additions to C# - records, tuples, deconstruction, nullable reference types, LINQ, extension methods, and a few others - which will be integrated with object-oriented and even procedural elements into a unified design which effectively solves a practical problem.

This session was presented several times (with a slightly changing title): IT Konekt 2021, Sinergija 2021 in Belgrade, NDC Porto 2022, Techorama Antwerp 2022, and Sinergija 2022.
Since those presentations, I have written the entire demo and script from scratch, including the latest syntax relevant to the topic, but also including feedback from previous conference talks.

Workshop: Gradually Improving Software Design (a.k.a. Applying the Emergent OOD)

Success is the greatest curse in a software project. The success that becomes unsustainable so quickly, that everything beyond the initial period of happiness becomes an endless maintenance and extension nightmare.

The primary motivation for this workshop is to help teams take control back and start making further progress in their (primarily) object-oriented designs, software projects that are often a couple of years old, and which are currently very hard to maintain and develop any further.

In this workshop, we are guiding developers through a series of experiments on pre-existing object-oriented designs modeling critical parts of business applications. Each of the designs is either exhibiting issues that are common to many object-oriented applications or is on the verge of becoming yet another object-oriented design ridden by problems: Lack of flexibility in the face of new requirements, inability to add more features and extend existing ones, desperate entanglement of all elements that cause further development to grind to a halt.

In each of the experiments, attendees will improve the design by removing one obstacle at a time. By the end, all those experimental designs will be turned into clean, extensible, and maintainable pieces of domain-related code.

Most of the examples that will be developed are ASP.NET Core applications in .NET 7 and C# 11. The particular choice of UI technologies is not relevant to the ability to participate in this workshop - all the code that is the subject of the workshop is in the domain-related classes. There is no preferred IDE - Visual Studio Code or Visual Studio 2022 (any edition) are fine, but any other that supports .NET 7 and C# 11 will suffice as well.

Table of contents:
Modeling emergent objects 50m
Modeling branching and looping 1h 30m
Implementing the map-reduce principle 2h 20m
Designing strategies 2h
Avoiding null references 2h 20m
Pattern matching (C# 7-11) and null operators 1h 20m
Modeling optional objects 2h 20m
Modeling Value Objects 2h 20m

Intermediate to advanced level.
I have been holding this workshop (both in the form of a 1-day workshop, 2-day workshop, or 1-day training) since 2014 to several dozens of teams, and also at some conferences. The content has sustained numerous evolutions and several complete rewrites.
The entire set of lectures is now in the form of an ASP.NET Core business application using EF Core, though UI & database technologies are not relevant for the content - even backend-only developers with little knowledge of EF core or UI had no problems participating.
The latest edition of this workshop was included in the SDD London 2023 conference.

Prerequisites:
- Proficiency in C#
- Proficiency in developing ASP.NET Core applications with EF Core is a plus, but not strictly required
- All attendees need their own laptop

Below are the tools and technologies required to develop the application. Each participant should have these installed on their laptop prior to attending the workshop:
- .NET SDK 7.0 or later - downloaded from https://dotnet.microsoft.com/enus/download/dotnet,
- An appropriate IDE, such as Visual Studio Code or Visual Studio (any edition,
including Community),
⎯ SQL Server support - all demos include a connection string to a LocalDB
database; support for LocalDB is installed as part of SQL Server Express (https://learn.microsoft.com/en-us/sql/database-engine/configure-windows/sql-server-express-localdb); any
other SQL Server edition would suffice but with the additional requirement
that the attendee would need to manage the connection string,
- SQL Server Management Studio (https://learn.microsoft.com/en-us/sql/ssms/download-sql-server-management-studio-ssms) or any other tool to easily browse and
query the database, including tools and extensions built into the IDE
- Git client, any

Beyond the Generative AI Hype: Code Generation Tools Are Here, Now What?

Generative AI is here, along with the growing hype about software development tools and, most intriguing, code-writing tools. The landscape is changing, but hardly anyone can tell in what way exactly.
While some developers worship AI and its power to develop entire features on a whim, others notice compile-time errors, calls made to nonexistent APIs, and outright delusional implementations! What is going on?
In this talk, we will try not to jump to conclusions but see the world as it is. Besides generating a portion of code, can an AI tool keep maintaining it in the upcoming years? Can it generate unit tests that will not break the same instant someone refactors the underlying implementation? (Was that a white box test? Come on, man!) Can a tool write excellent code, even though it was trained on myriads of lines of mediocre code? (Now, this was a trick question!)
Software development is more than writing down some code. In this talk, we shall try to evaluate the state of affairs as of the current date and to find a use for actual AI tools we do have available, not those coming from fairy tales.
Let it not be like writing the description above: Generated by an AI tool; proofread and improved by another AI tool; then written from scratch by a human.
And we didn't even touch on the process of specifying precise requirements...

This talk is a 100% coding session using C# in VS Code with Copilot and Copilot Chat extensions. Please keep this in mind when promoting the talk or selecting the audience.
This talk is the result of year-long experiments I ran and documented in a series of YouTube videos: https://youtube.com/playlist?list=PLSDYwLgFqaX4Ke4h0bVzgadqOesECqKj2

1-day Workshop: Functional Domain Modeling with C# 11

Domain modeling is probably the hardest part of modern software development and, beyond doubt, the most complicated process of them all. The complexity we observe in domain modeling comes from the intrinsic complexity of the domain itself - there are no simple businesses anymore. We must accept that.

Software developers have already observed that domain modeling benefits from functional programming. The reasons are manifold, but the most important ones have to do with how the functional modeling process is aligned with how businesses evolve (along with the software that models them).

It is beneficial to model the data separately from the rest of the system, and consequently to possess the domain state isolated from any processes. It is also beneficial to design functions separately from the data because behaviors are many and their stakeholders are often disconnected, often with little sympathy to the needs of others. Both these principles are orthogonal to object-oriented programming, but native to functional programming.

Hence this workshop, in which you will learn the benefits of functional modeling, on an example of a realistic ASP.NET Core Web application, as well as the practices and techniques we apply to implement the fully operational application.

Table of contents:
- Modeling the data separate from behavior,
- Modeling behavior on top of the data model,
- Using value objects and values; using records,
- Modeling discriminated unions,
- Modeling function composition,
- Optional objects and railway-oriented programming.

Prerequisites:
- Proficiency in C#; programmers mainly dedicated to other programming languages will probably not be able to follow through the workshop
- Proficiency in developing ASP.NET Core applications with EF Core is a plus, but not strictly required
- All attendees need their own laptop

Advanced level.
I have been holding this workshop (both in the form of a 1-day workshop, 2-day workshop, or 1-day training) since 2014 to several dozens of teams, and also at some conferences. The content has sustained numerous evolutions and several complete rewrites.
The entire set of lectures is now in the form of an ASP.NET Core business application using EF Core, though UI & database technologies are not relevant for the content - even backend-only developers with little knowledge of EF core or UI had no problems participating.

Where Is C# 12 Heading (and Why, Exactly?)

We have witnessed a gradual but substantial shift over the years in how the C# language is meant to be used. Between the lines, C# is becoming progressively functional, and for a reason!
In this session, we will demonstrate the use of the latest functional additions to C#, which are necessary to address the challenges in modern software development. We will outline the reasons why such a paradigm shift is a necessity in the cloud-first, reactive, parallel, event-driven, and whatnot world we are casting in software these days.
To adapt, some programmers will have to learn C# over again!

This talk was presented at Sinergija 2023 Belgrade (November 2023) and .NET Conf 2023 Bulgaria (December 2023).

Zoran Horvat

Principal consultant at Coding Helmet s.p.r.l.

Belgrade, Serbia