Peasy.NET

A business logic micro-framework for .NET and .NET Core

Github星跟踪图

peasy

A middle tier micro-framework for .NET and .NET Core

What's a middle tier framework?

A middle tier framework is code that facilitates creating business logic in a reusable, extensible, maintainable, and testable manner. It promotes creating business logic that is completely decoupled from its consuming technologies and helps to ensure that separation of concerns (SoC) are adhered to.

Peasy.NET offers/addresses the following:

The main actors

Data Proxy

The data proxy is responsible for data storage and retrieval, and serves as an abstraction layer for data stores (database, web services, cache, etc.).

Rule

A rule can be created to represent a business rule (authorization, price validity, etc.) or a validation rule (field length, required, etc.). Rules are consumed by commands and can be chained, configured to execute based on a previous rule’s execution, etc. Rules can also be configured to invoke code based on the result of their execution.

Command

The command is responsible for orchestrating the execution of initialization logic, business and validation rule execution, and other logic (data proxy invocations, workflow logic, etc.), respectively, via the command execution pipeline.

Business Service

A business service implementation represents an entity (e.g. users, or projects) and is responsible for exposing business functionality via commands. These commands encapsulate CRUD and other business related logic.

 

Peasy actors at work

Where can I get it?

Visual Studio

Install Peasy from the package manager console:

PM> Install-Package Peasy

VS Code

Install Peasy from the command line:

dotnet add package peasy

Getting started

You can get started by reviewing the getting started example on the Peasy wiki. The wiki also covers in-depth how-to's, general framework design, and usage scenarios.

You can also check out the samples repo that contains a sample implementation of a middle tier built with peasy, as well as sample consumer clients (WPF, Web API, ASP.NET MVC). You can clone the repo or download the entire project as a zip.

Once downloaded, open Orders.com.sln with Visual Studio, set the WPF or ASP.NET MVC project as the startup project and run. More information about the samples application can be found here.

Contributing

All contributions are welcome, from general framework improvements to sample client consumers, proxy implementations, and documentation updates. Want to get involved? Please hit us up with your ideas. Alternatively, you can make a pull request and we'll get to it ASAP.

Like what you see?

Please consider showing your support by starring the project.

主要指标

概览
名称与所有者peasy/Peasy.NET
主编程语言C#
编程语言C# (语言数: 1)
平台
许可证MIT License
所有者活动
创建于2015-04-14 02:52:51
推送于2024-01-29 13:27:53
最后一次提交2024-01-29 07:27:53
发布数21
最新版本名称v.5.1.1 (发布于 2022-09-24 06:56:03)
第一版名称peasy.core-v1.0.0.3 (发布于 2015-11-14 15:37:09)
用户参与
星数515
关注者数39
派生数69
提交数593
已启用问题?
问题数16
打开的问题数0
拉请求数5
打开的拉请求数0
关闭的拉请求数2
项目设置
已启用Wiki?
已存档?
是复刻?
已锁定?
是镜像?
是私有?