1 option
Practical Serverless and Microservices with C# : Build Resilient and Secure Microservices with the . NET Stack and Embrace Serverless Development in Azure.
- Format:
- Book
- Author/Creator:
- Baptista, Gabriel.
- Language:
- English
- Subjects (All):
- Microsoft Azure (Computing platform).
- Service-oriented architecture (Computer science).
- Physical Description:
- 1 online resource (472 pages)
- Edition:
- 1st ed.
- Place of Publication:
- Birmingham : Packt Publishing, Limited, 2025.
- Summary:
- From the authors of the Software Architecture with C# and .NET series comes this practical and grounded showcase of microservices using the .NET stack. Written for .NET developers entering the world of modern cloud and distributed applications, it shows you when microservices and serverless architectures are the right choice for building scalable enterprise solutions and when they're not. You'll gain a realistic understanding of their use cases and limitations. Rather than promoting microservices as a one-size-fits-all solution, it encourages thoughtful adoption based on real-world needs. Following a brief introduction and important setup, the book helps you prepare for practical application through examples such as a ride-sharing website. You'll work with Docker, Kubernetes, Azure Container Apps, and the new .NET Aspire with considerations for security, observability, and cost management. The book culminates in a complete event-driven application that brings together everything you've covered. By the end of the book, you'll have a well-rounded understanding of cloud and distributed .NET--viewed through the lens of two industry veterans.
- Contents:
- Intro
- Title Page
- Credit Page
- Contributors
- Table of Contents
- Preface
- Free Benefits with Your Book
- Chapter 1: Demystifying Serverless Applications
- Technical requirements
- What is serverless?
- Is serverless a way to deliver microservices?
- How does Microsoft Azure present serverless?
- Creating your first serverless app in Azure
- Understanding the triggers available in Azure Functions
- Coding with Azure Functions
- Coding Azure functions using VS Code
- Coding Azure functions using Visual Studio
- Summary
- Questions
- Further reading
- Chapter 2: Demystifying Microservices Applications
- The rise of Service-Oriented Architectures (SOAs) and microservices
- The rise of SOA
- Toward microservices architectures
- The definition and organization of microservices architectures
- A definition of microservices architectures
- Domain of expertise and microservices
- Replicable microservices
- Splitting microservices development among different teams
- Microservices, interfaces, and communication protocols
- Just the interfaces of the logical microservices are public
- Microservices organization
- Car-sharing example
- When is it worth adopting microservices architectures?
- Microservices common patterns
- Resilient task execution
- Efficacious handling of asynchronous communication
- Event-based communications
- Interfacing the external world
- Chapter 3: Setup and Theory: Docker and Onion Architecture
- The Onion Architecture
- The Domain layer
- Application services
- Queries
- Commands
- Domain events
- A solution template based on the Onion Architecture
- Matching aggregates and ORM entities
- A complete solution based on the Onion Architecture
- Containers and Docker.
- Docker Desktop: a simple example
- A few more Docker commands and options
- Visual Studio support for Docker
- Chapter 4: Azure Functions and Triggers Available
- HTTP trigger
- Advantages, disadvantages, and when to use the HTTP trigger
- Car-sharing HTTP trigger example
- Advantages, disadvantages, and when to use the Azure SQL trigger
- Car-sharing SQL trigger example
- Advantages, disadvantages, and when to use the Cosmos DB trigger
- Car-sharing Cosmos DB trigger example
- Azure Service Bus trigger
- Comparison with the Kafka trigger and the RabbitMQ trigger
- Car-sharing example with the Azure Service Bus trigger
- Chapter 5: Background Functions in Practice
- Timer trigger
- Publishing your functions
- Monitoring your functions
- Advantages, disadvantages, and when to use Azure timer triggers
- Car-sharing timer trigger example
- Blob trigger
- Advantages, disadvantages, and when to use Blob storage triggers
- Blob trigger implementation using Event Grid
- Car-sharing Blob storage trigger example
- Queue storage trigger
- Advantages, disadvantages, and when to use queue storage triggers
- Car-sharing queue storage trigger example
- Join our community on Discord
- Chapter 6: IoT Functions in Practice
- Enabling IoT in Azure
- Connecting IoT Hub with Azure Functions
- Car-sharing IoT example
- Chapter 7: Microservices in Practice
- The route-planning microservice of the car-sharing application
- Microservice specifications
- Handling security and authorization
- Creating the Visual Studio solution
- Microservice basic design.
- The message broker: RabbitMQ
- Input communication
- Output communication
- Ensuring that messages are processed in the proper order
- Designing Docker image environment parameters
- The microservice main service
- EasyNetQ's RPC facilities
- Other required hosted services
- Ensuring resilient task execution with Polly
- The Polly library
- Adding Polly to our project
- From abstraction to implementation details
- The domain layer
- The route request aggregate
- The route offer aggregate
- The output queue item aggregate
- The database driver
- The IOutputQueueRepository implementation
- The IRouteRequestRepositoryimplementation
- The IRouteOfferRepository implementation
- Creating migrations and databases
- The application services: Defining all command and event handlers
- Coding all event handlers
- Chapter 8: Practical Microservices Organization with Kubernetes
- Introduction to orchestrators and their configuration
- .yaml files
- Kubernetes basics
- Interacting with Kubernetes: Kubectl, Minikube, and AKS
- Creating an Azure Kubernetes cluster
- Configuring your application in Kubernetes
- Dynamic provisioning of permanent disk space
- ReplicaSets, Deployments, and their services
- StatefulSets and Headless Services
- Scaling and autoscaling
- Resource metrics
- Pod metrics
- Object metrics
- Running your microservices on Kubernetes
- Organizing all deployment environments
- Database engine and database installation
- Container registries
- Message broker installation
- Debugging techniques
- Testing the route-matching worker microservice
- Advanced Kubernetes configuration
- Secrets
- Readiness, liveness, and startup probes
- Ingresses
- Testing Ingresses with Minikube
- Using an NGNIX-based Ingress in AKS
- Summary.
- Questions
- Chapter 9: Simplifying Containers and Kubernetes: Azure Container Apps, and Othert Tools
- Tools for simplifying Kubernetes clusters usage and administration
- Helm and Helm charts
- Kubernetes graphic UIs
- Kubernetes administrative tools
- Development environments based on Kubernetes
- Azure Container Apps basics and plans
- Consumption-only and workload profiles
- Application versioning
- Interacting with Azure Container Apps
- Deploying your microservice application with Azure Container Apps
- Basic commands and operativity
- Application configuration options and the .yaml format
- Container configuration
- The ingress configuration
- Volume definition and allocation
- Associating an Azure identity to your application
- Chapter 10: Security and Observability for Serverless and Microservices Applications
- Application Security Best Practices
- Network Security
- Data Security
- Authentication and Authorization
- JSON Web Tokens
- OAuth 2.0 and OpenID Connect (OIDC)
- Securing Dependencies
- Kubernetes and Azure Container Apps Security
- Kubernetes network security
- Azure Container Apps Network Security
- Kubernetes User Security
- Azure Container Apps User Security
- Threat Detection and Mitigation
- Threats
- Event Injection
- Privilege Escalation
- Denial of Service (DoS) Attacks
- Man-in-the-Middle (MitM) Attacks
- Code Injection
- Detection and Mitigation with Web Application Firewalls
- Observability for Serverless and Microservices
- Logging
- Metrics
- Tracing
- Centralized Observability with Azure Monitor
- Chapter 11: The Car Sharing App
- General architecture description
- Microservices involved
- Authorization microservice
- CarSharer microservice.
- CarRequests microservice
- RoutesPlanning microservice
- Email microservice
- The demonstration code
- Chapter 12: Simplifying Microservices with .NET Aspire
- .NET Aspire features and services
- Service discovery and its role in .NET Aspire.
- Resource integration and automatic resource configuration
- Application telemetry
- Configuring microservices and resources
- Azure Functions integration
- Using .NET Aspire in practice
- RabbitMQ integration
- Deploying a .NET Aspire project
- Chapter 13: Unlock Your Exclusive Benefits
- Unlock this Book's Free Benefits in 3 Easy Steps
- Other Books You May Enjoy
- Index
- Blank Page.
- Notes:
- Description based on publisher supplied metadata and other sources.
- ISBN:
- 1-83664-200-8
- OCLC:
- 1521989544
The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.