Skip to content

๐ŸŽฏ Why Choose Bazario?

๐Ÿ”„ Synchronous & Asynchronous Support

Most libraries require choosing between synchronous or asynchronous processing, limiting flexibility.

โœจ Bazario's Solution:
The bazario.asyncio package supports both synchronous and asynchronous handling, giving you complete freedom in your application architecture.

๐ŸŽฎ IoC Container Control

Traditional libraries handle IoC containers internally, leading to bugs and side effects, reducing performance with multiple parallel containers.

โœจ Bazario's Solution:
Bazario allows the client to control the IoC container and scope creation, giving full control over the containerโ€™s lifecycle and preventing performance issues or side effects caused by redundant container instances.

๐Ÿงฉ Enhanced Modularity

In other libraries, integrating different DI frameworks is challenging without rewriting significant portions of the logic.

โœจ Bazario's Solution:
Bazario solves this problem by utilizing a modular resolvers system, allowing easy integration with any DI framework. This provides the ability to use Bazario in different environments without being tied to a specific DI framework.

โšก SOLID Principles Adherence

Some libraries do not fully adhere to SOLID principles, making the code more complex and harder to maintain.

โœจ Bazario's Solution:
Bazario fully adheres to SOLID principles, particularly ISP (Interface Segregation Principle). For example, instead of tightly coupling everything to a Dispatcher, Bazario separates responsibilities by introducing the Publisher protocol for event publication and the Sender protocol for sending requests, leading to better responsibility separation and reduced unnecessary dependencies.

๐Ÿ”ฑ Dependency Separation

Traditional controllers handle both request parsing and handler resolution, increasing complexity and reducing testability.

โœจ Bazario's Solution:
Bazario addresses this by delegating all handler routing responsibilities to Bazario, allowing controllers to focus solely on parsing requests. This improves responsibility separation and makes controller code cleaner and more testable.

๐Ÿ”— Advanced Pipeline System

Many libraries lack effective ways to implement cross-cutting concerns like logging, validation, or error handling.

โœจ Bazario's Solution:
Bazario addresses this by offering a sophisticated behavior pipeline system that allows developers to:

  • ๐Ÿ”„ Middleware without handler modifications
  • ๐Ÿงฉ Reusable components
  • โš™๏ธ Flexible request/notification chains
  • ๐Ÿ“Š Centralized monitoring
  • ๐Ÿ“ Unified logging
  • โŒ Consistent error handling

This powerful pipeline system allows developers to manage complex workflows efficiently and with minimal code duplication.

โš™๏ธ Flexible Processing Control

Developers face challenges when introducing new processing requirements, especially when they require changing existing handler logic.

โœจ Bazario's Solution:
Bazario offers flexible control over how requests and notifications are processed through:

  • ๐ŸŽฏ Type-specific pipeline behaviors
  • ๐ŸŒ Global behavior configuration
  • ๐Ÿ“‹ Configurable execution order
  • ๐Ÿ”„ Non-intrusive requirement integration