An Atypical ASP.NET Core 6 Design Patterns Guide
eBook - ePub

An Atypical ASP.NET Core 6 Design Patterns Guide

Carl-Hugo Marcotte, Abdelhamid Zebdi

Buch teilen
  1. 678 Seiten
  2. English
  3. ePUB (handyfreundlich)
  4. Über iOS und Android verfĂŒgbar
eBook - ePub

An Atypical ASP.NET Core 6 Design Patterns Guide

Carl-Hugo Marcotte, Abdelhamid Zebdi

Angaben zum Buch
Buchvorschau
Inhaltsverzeichnis
Quellenangaben

Über dieses Buch

The professional developer's essential guide to building robust, maintainable, and flexible web apps by leveraging C# 10 and.NET 6 features and component- and application-scale design patternsKey Features‱ Apply the SOLID architectural principles and software design patterns effectively with a focus on dependency injection‱ Discover modern application architectures such as vertical slice, clean architecture, and event-driven microservices‱ Explore full-stack ASP.NET Core with an overview of BlazorBook DescriptionAn Atypical ASP.NET Core 6 Design Patterns Guide, Second Edition approaches programming like playing with LEGO¼: snapping small pieces together to create something beautiful. Thoroughly updated for ASP.NET Core 6, with further coverage of microservices patterns, data contracts, and event-driven architecture, this book gives you the tools to build and glue reliable components together to improve your programmatic masterpieces. The chapters are organized based on scale and topic, allowing you to start small and build on a strong base, the same way that you would develop a program. You will begin by exploring basic design patterns, SOLID architectural principles, dependency injection, and other ASP.NET Core 6 mechanisms. You will explore component-scale patterns, and then move to higher level application-scale patterns and techniques to better structure your applications. Finally, you'll advance to the client side to connect the dots with tools like Blazor and make ASP.NET Core a viable full-stack web development framework. You will supplement your learning with practical use cases and best practices, exploring a range of significant Gang of Four (GoF) design patterns along the way. By the end of the book, you will be comfortable combining and implementing patterns in different ways, and crafting software solutions of any scale.What you will learn‱ Apply the SOLID principles for building flexible and maintainable software‱ Get to grasp.NET dependency Injection‱ Work with GoF design patterns such as strategy, decorator, façade, and composite‱ Explore the MVC patterns for designing web APIs and web applications using Razor‱ Discover layering techniques and tenets of clean architecture‱ Become familiar with CQRS and vertical slice architecture as an alternate to layering‱ Understand microservices and when they can benefit your applications‱ Build an ASP.NET user interfaces from server-side to client-side BlazorWho this book is forThe book is intended for intermediate software and web developers with an understanding of.NET who want to write flexible, maintainable, and robust code for building scalable web applications. Knowledge of C# programming and an understanding of web concepts like HTTP is necessary.

HĂ€ufig gestellte Fragen

Wie kann ich mein Abo kĂŒndigen?
Gehe einfach zum Kontobereich in den Einstellungen und klicke auf „Abo kĂŒndigen“ – ganz einfach. Nachdem du gekĂŒndigt hast, bleibt deine Mitgliedschaft fĂŒr den verbleibenden Abozeitraum, den du bereits bezahlt hast, aktiv. Mehr Informationen hier.
(Wie) Kann ich BĂŒcher herunterladen?
Derzeit stehen all unsere auf MobilgerĂ€te reagierenden ePub-BĂŒcher zum Download ĂŒber die App zur VerfĂŒgung. Die meisten unserer PDFs stehen ebenfalls zum Download bereit; wir arbeiten daran, auch die ĂŒbrigen PDFs zum Download anzubieten, bei denen dies aktuell noch nicht möglich ist. Weitere Informationen hier.
Welcher Unterschied besteht bei den Preisen zwischen den AboplÀnen?
Mit beiden AboplÀnen erhÀltst du vollen Zugang zur Bibliothek und allen Funktionen von Perlego. Die einzigen Unterschiede bestehen im Preis und dem Abozeitraum: Mit dem Jahresabo sparst du auf 12 Monate gerechnet im Vergleich zum Monatsabo rund 30 %.
Was ist Perlego?
Wir sind ein Online-Abodienst fĂŒr LehrbĂŒcher, bei dem du fĂŒr weniger als den Preis eines einzelnen Buches pro Monat Zugang zu einer ganzen Online-Bibliothek erhĂ€ltst. Mit ĂŒber 1 Million BĂŒchern zu ĂŒber 1.000 verschiedenen Themen haben wir bestimmt alles, was du brauchst! Weitere Informationen hier.
UnterstĂŒtzt Perlego Text-zu-Sprache?
Achte auf das Symbol zum Vorlesen in deinem nÀchsten Buch, um zu sehen, ob du es dir auch anhören kannst. Bei diesem Tool wird dir Text laut vorgelesen, wobei der Text beim Vorlesen auch grafisch hervorgehoben wird. Du kannst das Vorlesen jederzeit anhalten, beschleunigen und verlangsamen. Weitere Informationen hier.
Ist An Atypical ASP.NET Core 6 Design Patterns Guide als Online-PDF/ePub verfĂŒgbar?
Ja, du hast Zugang zu An Atypical ASP.NET Core 6 Design Patterns Guide von Carl-Hugo Marcotte, Abdelhamid Zebdi im PDF- und/oder ePub-Format sowie zu anderen beliebten BĂŒchern aus Informatica & Programmazione Microsoft. Aus unserem Katalog stehen dir ĂŒber 1 Million BĂŒcher zur VerfĂŒgung.

Information

Jahr
2022
ISBN
9781803243887

Section 1: Principles and Methodologies

This section focuses on architectural principles and development methodologies that we use throughout the book. These introductory chapters are essential for progressing toward making great architectural decisions.
We first look at how to approach the book itself, explore prerequisites, and see a few helpful topics. Then, we cover automated testing and xUnit, to finally jump into the architectural principles, where we begin our study of the fundamentals of modern software engineering.
This section comprises the following chapters:
  • Chapter 1, Introduction
  • Chapter 2, Automated Testing
  • Chapter 3, Architectural Principles

1

Introduction

The goal of this book is not to create yet another design pattern book; instead, the chapters are organized according to scale and topic, allowing you to start small with a strong foundation and build slowly upon it, in just the same way that you would build a program.
Instead of this being a guide that covers a few ways of applying a design pattern, we will explore the thought processes behind the systems we are designing from a software engineer’s point of view.
This is not a magic recipe book, and from experience, there is no magic recipe when designing software; there is only your logic, knowledge, experience, and analytical skills. Let’s define “experience” as your past successes and failures. And don’t worry, you will fail during your career, but don’t get discouraged by it. The faster you fail, the faster you can recover and learn, leading to successful products. Many techniques covered in this book should help you achieve that goal. Everyone has failed and made mistakes; you aren’t the first, and you certainly won’t be the last. To paraphrase a well-known saying of Roosevelt’s, the people that never fail are the ones who never do anything.
The high-level plan looks like this:
  • We will explore basic patterns, unit testing, architectural principles, and some crucial ASP.NET Core mechanisms.
  • Then, we will move up to the component scale, exploring patterns oriented toward small chunks of software and individual units.
  • After that, we will move to application-scale patterns and techniques, where we explore higher-level patterns and how to structure an application as a whole.
  • Afterward, we will tackle the client side to connect the dots and make ASP.NET a viable full stack alternative.
Many subjects covered throughout the book could have a book of their own. Once you are done with this book, you should have plenty of ideas about where to continue your journey into software architecture.
Here are a few pointers that I believe are worth stating:
  • The chapters are organized to start with small-scale patterns and then progress to higher-level ones, making the learning curve easier.
  • Instead of giving you a recipe, the book focuses on the thinking behind things and shows the evolution of some techniques to help you understand why the evolution happened.
  • Many use cases combine more than one design pattern to illustrate alternate usage, so that you can understand the patterns and use them efficiently. This also shows that design patterns are not beasts to tame but tools to use, manipulate, and bend to your will.
  • As in real life, no textbook solution can solve all our problems, and real problems are always more complicated than what’s explained in textbooks. In this book, my goal is to show you how to mix and match patterns to think “architecture,” instead of giving you step-by-step instructions to reproduce.
This chapter introduces the different concepts that we will be exploring throughout the book, including refreshers on a few notions. We will also cover .NET and its tooling, as well as the technical requirements, such as where the source code is located.
The following topics will be covered in this chapter:
  • What is a design pattern?
  • Anti-patterns and code smells
  • Understanding the web – request/response
  • Getting started with .NET

What is a design pattern?

Since you just purchased a book about design patterns, I guess that you have some idea of what design patterns are, but let’s just make sure that we are on the same page.
Abstract definition: A design pattern is a proven technique that can be used to solve a specific problem.
In this book, we will apply different patterns to solve different problems and leverage some open source tools to go further, faster! Abstract definitions make people sound intelligent and all, but there is no better way to learn than by experimenting with something, and design patterns are no different.
If that definition does not make sense to you yet, don’t worry. You should have enough information by the end of the book to correlate the multiple practical examples and explanations with that definition, making it clear enough.
I like to compare programming to playing with LEGO¼ because what you have to do is generally the same: put small pieces together to create something bigger. It could be a castle, a spaceship, or something else that you want to build. With that analogy in mind, a design pattern is a plan to assemble a solution that fits one or more scenarios; a tower or a reactor, for example. Therefore, if you lack imagination or skills in the case of LEGO¼, possibly because you are too young, your castle might not look as good as someone else’s who has more experience. Design patterns give you the tools you need, helping you put beautiful and reliable pieces together to improve your masterpiece.
However, instead of snapping LEGOÂź blocks together, you nest code blocks and interweave objects in a virtual environment!
Before going into more detail, well-thought-out applications of design patterns should improve your application designs. That is true whether you are designing a small component or a whole system. However, be careful: throwing patterns into the mix just to use them can lead to the opposite result. Aim to write readable code that solves the issue at hand, not at over-engineering systems with as many patterns as ...

Inhaltsverzeichnis