,

Architecture Patterns with Python

Paperback Engels 2020 1e druk 9781492052203
€ 78,21
Levertijd ± 16 werkdagen
Gratis verzonden
Past door de brievenbus

Samenvatting

As Python continues to grow in popularity, projects are becoming larger and more complex. Many Python developers are taking an interest in high-level software design patterns such as hexagonal/clean architecture, event-driven architecture, and the strategic patterns prescribed by domain-driven design (DDD). But translating those patterns into Python isn’t always straightforward.

With this hands-on guide, Harry Percival and Bob Gregory from MADE.com introduce proven architectural design patterns to help Python developers manage application complexity—and get the most value out of their test suites.

Each pattern is illustrated with concrete examples in beautiful, idiomatic Python, avoiding some of the verbosity of Java and C# syntax.

Patterns include:
- Dependency inversion and its links to ports and adapters (hexagonal/clean architecture)
- Domain-driven design’s distinction between Entities, Value Objects, and Aggregates
- Repository and Unit of Work patterns for persistent storage
- Events, commands, and the message bus
- Command-query responsibility segregation (CQRS)
- Event-driven architecture and reactive microservices

Specificaties

ISBN13:9781492052203
Taal:Engels
Bindwijze:paperback
Aantal pagina's:280
Uitgever:O'Reilly
Druk:1
Verschijningsdatum:20-3-2020
Hoofdrubriek:IT-management / ICT

Lezersrecensies

Wees de eerste die een lezersrecensie schrijft!

Over Harry Percival

After an idyllic childhood spent playing with BASIC on French 8-bitcomputers like the Thomson T-07 whose keys go "boop" when you press them, Harry went on to study Economics and Philosophy at Cambridge University. He then spent a few years being deeply unhappy as a management consultant. Soon he rediscovered his true geek nature, and was lucky enough to fall in with a bunch of XP fanatics, working on the pioneering but sadly defunct Resolver One spreadsheet. He now works at PythonAnywhere LLP, and spreads the gospel of TDD world-wide at talks, workshops and conferences, with all the passion and enthusiasm of a recent convert.

Andere boeken door Harry Percival

Over Bob Gregory

Bob Gregory is a UK-based software architect with MADE.COM. He has been building event driven systems with domain-driven design for more than a decade.

Andere boeken door Bob Gregory

Inhoudsopgave

Preface
Managing Complexity, Solving Business Problems
Why Python?
TDD, DDD, and Event-Driven Architecture
Who Should Read This Book
A Brief Overview of What You’ll Learn
Part I, Building an Architecture to Support Domain Modeling
Part II, Event-Driven Architecture
Addtional Content
Example Code and Coding Along
License
Conventions Used in This Book
O’Reilly Online Learning
How to Contact O’Reilly
Acknowledgments
Introduction
Why Do Our Designs Go Wrong?
Encapsulation and Abstractions
Layering
The Dependency Inversion Principle
A Place for All Our Business Logic: The Domain Model

I. Building an Architecture to Support Domain Modeling
1. Domain Modeling
What Is a Domain Model?
Exploring the Domain Language
Unit Testing Domain Models
Dataclasses Are Great for Value Objects
Value Objects and Entities
Not Everything Has to Be an Object: A Domain Service Function
Python’s Magic Methods Let Us Use Our Models with Idiomatic Python
Exceptions Can Express Domain Concepts Too

2. Repository Pattern
Persisting Our Domain Model
Some Pseudocode: What Are We Going to Need?
Applying the DIP to Data Access
Reminder: Our Model
The “Normal” ORM Way: Model Depends on ORM
Inverting the Dependency: ORM Depends on Model
Introducing the Repository Pattern
The Repository in the Abstract
What Is the Trade-Off?
Building a Fake Repository for Tests Is Now Trivial!
What Is a Port and What Is an Adapter, in Python?
Wrap-Up

3. A Brief Interlude: On Coupling and Abstractions
Abstracting State Aids Testability
Choosing the Right Abstraction(s)
Implementing Our Chosen Abstractions
Testing Edge to Edge with Fakes and Dependency Injection
Why Not Just Patch It Out?
Wrap-Up

4. Our First Use Case: Flask API and Service Layer
Connecting Our Application to the Real World
A First End-to-End Test
The Straightforward Implementation
Error Conditions That Require Database Checks
Afgekapt op 60 regels

Managementboek Top 100

€ 78,21
Levertijd ongeveer 16 werkdagen
Gratis verzonden

Rubrieken

Producten

    Auteurs

      Trefwoorden

        Artikelen

          Architecture Patterns with Python