Book Image

Mastering ABP Framework

By : Halil İbrahim Kalkan
Book Image

Mastering ABP Framework

By: Halil İbrahim Kalkan

Overview of this book

ABP Framework is a complete infrastructure for creating modern web applications by following software development best practices and conventions. With ABP's high-level framework and ecosystem, you can implement the Don’t Repeat Yourself (DRY) principle and focus on your business code. Written by the creator of ABP Framework, this book will help you to gain a complete understanding of the framework and modern web application development techniques. With step-by-step explanations of essential concepts and practical examples, you'll understand the requirements of a modern web solution and how ABP Framework makes it enjoyable to develop your own solutions. You'll discover the common requirements of enterprise web application development and explore the infrastructure provided by ABP. Throughout the book, you’ll get to grips with software development best practices for building maintainable and modular web solutions. By the end of this book, you'll be able to create a complete web solution that is easy to develop, maintain, and test.
Table of Contents (24 chapters)
1
Part 1: Introduction
6
Part 2: Fundamentals of ABP Framework
11
Part 3: Implementing Domain–Driven Design
15
Part 4: User Interface and API Development
19
Part 5: Miscellaneous

Publishing domain events

Domain events are used to inform other components and services about an important change to a domain object so that they can take action.

ABP Framework provides two types of event buses to publish domain events, each with a different purpose:

  • The local event bus is used to notify the handlers in the same process.
  • The distributed event bus is used to notify the handlers in the same or different processes.

Publishing and handling events are pretty easy with ABP Framework. The next section shows how to work with the local event bus, and then we will look at the distributed event bus.

Using the local event bus

A local event handler is executed in the same unit of work (in the same local database transaction). If you are building a monolith application or want to handle events in the same service, the local event bus is fast and safe to use because it works in the same process.

Assume that you want to publish a local event when an...