ASP.NET Core 9 Web API Cookbook: Over 60 hands-on recipes for building and securing enterprise web APIs with REST, GraphQL, and more
暫譯: ASP.NET Core 9 網頁 API 食譜:超過 60 個實作範例,構建與保護企業網頁 API,涵蓋 REST、GraphQL 等技術

Avedon, Luke, Cabrera, Garry

  • 出版商: Packt Publishing
  • 出版日期: 2025-04-24
  • 售價: $1,570
  • 貴賓價: 9.5$1,492
  • 語言: 英文
  • 頁數: 344
  • 裝訂: Quality Paper - also called trade paper
  • ISBN: 1835880347
  • ISBN-13: 9781835880340
  • 相關分類: .NETASP.NETWeb API
  • 海外代購書籍(需單獨結帳)

相關主題

商品描述

Embrace the future of web API development with ASP.NET Core 9-from REST best practices to real-time SignalR, and from HybridCache to .NET Aspire deployment-through hands-on recipes and proven methodologies

Key Features:

- Master the lifecycle of ASP.NET Core web APIs by confidently building, testing, monitoring, and securing your applications

- Explore advanced topics like GraphQL, SignalR, and microservices to create feature-rich APIs

- Discover cloud deployment strategies to ensure your APIs are ready for modern infrastructure

- Purchase of the print or Kindle book includes a free PDF eBook

Book Description:

Discover what makes ASP.NET Core 9 a powerful and versatile framework for building modern web APIs that are both scalable and secure. This comprehensive, recipe-based guide leverages the authors' decade-long experience in software development to equip developers with the knowledge to create robust web API solutions using the framework's most powerful features.

Designed for intermediate to advanced .NET developers, this cookbook contains hands-on recipes that demonstrate how to efficiently build, optimize, and secure APIs using this cutting-edge technology. You'll master essential topics, such as creating RESTful APIs, implementing advanced data access strategies, securing your APIs, creating custom middleware, and enhancing your logging capabilities. The book goes beyond traditional API development by introducing GraphQL, SignalR, and gRPC, offering insights into how these technologies can extend the reach of your APIs. To prepare you for real-world challenges, the recipes cover testing methodologies, cloud deployment, legacy system integration, and advanced concepts like microservices and Hangfire.

By the end of this book, you'll gain the expertise needed to build and manage enterprise-grade web APIs with ASP.NET Core 9.

What You Will Learn:

- Implement HybridCache with stampede protection to replace distributed and in-memory caches

- Perform unit, integration, and contract testing to ensure robustness and reliability

- Optimize API performance using output and response caching with tag-based invalidation

- Design custom middleware for rate limiting, centralized exception handling, health checks, and more

- Streamline API troubleshooting using Serilog's structured logging and Seq's powerful log visualization for quick insights

- Secure your APIs with authentication, authorization, and HTTPS enforcement

Who this book is for:

This book is for intermediate to advanced developers-whether you're a .NET, backend, full-stack, or DevOps professional-looking to build and secure APIs with ASP.NET Core. It's also ideal for those experienced in Java or Go who want to transition to ASP.NET Core, or developers familiar with C# and .NET aiming to deepen their API skills. A working knowledge of web APIs and the .NET ecosystem is assumed, so you can jump straight into practical recipes.

Table of Contents

- Practical Data Access in ASP.NET Core Web APIs

- Mastering Resource Creation and Validation

- Securing Your Web API

- Creating Custom Middleware

- Creating Comprehensive Logging Solutions

- Real-Time Communication with SignalR

- Building Robust API Tests: a Guide to Unit and Integration Testing

- GraphQL: Designing Flexible and Efficient APIs

- Deploying and Managing Your WebAPI in the Cloud

- The Craft of Caching

- Beyond the Core

商品描述(中文翻譯)

擁抱 ASP.NET Core 9 的網頁 API 開發未來 - 從 REST 最佳實踐到即時 SignalR,從 HybridCache 到 .NET Aspire 部署 - 通過實作食譜和經驗豐富的方法論

主要特點:

- 自信地構建、測試、監控和保護您的應用程式,掌握 ASP.NET Core 網頁 API 的生命週期
- 探索 GraphQL、SignalR 和微服務等進階主題,以創建功能豐富的 API
- 發現雲端部署策略,以確保您的 API 為現代基礎設施做好準備
- 購買印刷版或 Kindle 書籍可獲得免費 PDF 電子書

書籍描述:

了解為何 ASP.NET Core 9 是一個強大且多功能的框架,適合構建可擴展且安全的現代網頁 API。本書是一本全面的食譜式指南,利用作者十年的軟體開發經驗,幫助開發者掌握使用框架最強大功能來創建穩健的網頁 API 解決方案的知識。

本書專為中級至高級 .NET 開發者設計,包含實作食譜,展示如何有效地構建、優化和保護 API,使用這項尖端技術。您將掌握基本主題,如創建 RESTful API、實施進階數據存取策略、保護您的 API、創建自定義中介軟體以及增強日誌記錄能力。本書超越傳統的 API 開發,介紹 GraphQL、SignalR 和 gRPC,提供這些技術如何擴展您的 API 的見解。為了讓您準備好面對現實挑戰,食譜涵蓋測試方法論、雲端部署、舊系統整合以及微服務和 Hangfire 等進階概念。

在本書結束時,您將獲得使用 ASP.NET Core 9 構建和管理企業級網頁 API 所需的專業知識。

您將學到的內容:

- 實施帶有衝擊保護的 HybridCache,以取代分散式和內存快取
- 執行單元測試、整合測試和合約測試,以確保穩健性和可靠性
- 使用基於標籤的失效的輸出和響應快取來優化 API 性能
- 設計自定義中介軟體以進行速率限制、集中式異常處理、健康檢查等
- 使用 Serilog 的結構化日誌記錄和 Seq 的強大日誌可視化來簡化 API 故障排除,快速獲取見解
- 通過身份驗證、授權和 HTTPS 強制來保護您的 API

本書適合誰:

本書適合中級至高級開發者 - 無論您是希望使用 ASP.NET Core 構建和保護 API 的 .NET、後端、全端或 DevOps 專業人士。對於那些有 Java 或 Go 經驗並希望轉向 ASP.NET Core 的人,或是熟悉 C# 和 .NET 的開發者,想要深化其 API 技能的人,本書也非常理想。本書假設您對網頁 API 和 .NET 生態系統有基本了解,因此您可以直接進入實用食譜。

目錄

- ASP.NET Core 網頁 API 的實用數據存取
- 掌握資源創建和驗證
- 保護您的網頁 API
- 創建自定義中介軟體
- 創建全面的日誌解決方案
- 使用 SignalR 進行即時通訊
- 構建穩健的 API 測試:單元測試和整合測試指南
- GraphQL:設計靈活且高效的 API
- 在雲端部署和管理您的 WebAPI
- 快取的技藝
- 超越核心