登录 注册
内容创作与媒体工具
7,125
Stars
1,330
Forks
294
Watchers
9
Open Issues
MIT
许可证
C#
语言
2016-12-14
创建时间
2026-11-09
最近更新

项目能做什么

基于最终一致性的微服务分布式事务解决方案,同时是支持 Outbox 模式的 EventBus。
来源:AI 基于仓库事实生成 · 内容以仓库实际 README 为准

使用说明 查看原始 README 原仓库文档

中文使用说明暂未生成。下面保留原仓库 README 摘录,命令与配置均以原文为准。
原始 README 摘录(英文原文,节选前 3000 字符)
<p align="center">
  <img height="140" src="https://raw.githubusercontent.com/dotnetcore/CAP/master/docs/content/img/logo.svg" alt="CAP Logo">
</p>

# CAP                     [中文](https://github.com/dotnetcore/CAP/blob/master/README.zh-cn.md)

[![Docs & Dashboard](https://github.com/dotnetcore/CAP/actions/workflows/deploy-docs-and-dashboard.yml/badge.svg?branch=master)](https://github.com/dotnetcore/CAP/actions/workflows/deploy-docs-and-dashboard.yml)
[![AppVeyor](https://ci.appveyor.com/api/projects/status/v8gfh6pe2u2laqoa/branch/master?svg=true)](https://ci.appveyor.com/project/yang-xiaodong/cap/branch/master)
[![NuGet](https://img.shields.io/nuget/v/DotNetCore.CAP.svg)](https://www.nuget.org/packages/DotNetCore.CAP/)
[![NuGet Preview](https://img.shields.io/nuget/vpre/DotNetCore.CAP.svg?label=nuget-pre)](https://www.nuget.org/packages/DotNetCore.CAP/)
[![Member project of .NET Core Community](https://img.shields.io/badge/member%20project%20of-NCC-9e20c9.svg)](https://github.com/dotnetcore)
[![GitHub license](https://img.shields.io/badge/license-MIT-blue.svg)](https://raw.githubusercontent.com/dotnetcore/CAP/master/LICENSE.txt)

CAP is a .NET library that provides a lightweight, easy-to-use, and efficient solution for distributed transactions and event bus integration.

When building SOA or Microservice-based systems, services often need to be integrated via events. However, simply using a message queue cannot guarantee reliability. CAP leverages a local message table, integrated with your current database, to solve exceptions that can occur during distributed system communications. This ensures that event messages are never lost.

You can also use CAP as a standalone EventBus. It offers a simplified approach to event publishing and subscribing without requiring you to inherit or implement any specific interfaces.

## Key Features

*   **Core Functionality**
    *   **Distributed Transactions**: Guarantees data consistency across microservices using a local message table (Outbox Pattern).
    *   **Event Bus**: High-performance, lightweight event bus for decoupled communication.
    *   **Guaranteed Delivery**: Ensures messages are never lost, with automatic retries for failed messages.

*   **Advanced Messaging**
    *   **Delayed Messages**: Native support for publishing messages with a delay, without relying on message queue features.
    *   **Flexible Subscriptions**: Supports attribute-based, wildcard (`*`, `#`), and partial topic subscriptions.
    *   **Consumer Groups & Fan-Out**: Easily implement competing consumer or fan-out patterns for load balancing or broadcasting.
    *   **Parallel & Serial Processing**: Configure consumers for high-throughput parallel processing or ordered sequential execution.
    *   **Backpressure Mechanism**: Automatically manages processing speed to prevent memory overload (OOM) under high load.

*   **Extensibility & Integration**
    *   **Pluggable Architecture**: Supports a wide range of message queue
阅读完整原文

项目深度分析 AI 生成

CAP Enterprise Management Dashboard (商业版增强管控中心)

产品构想基于内置简易 Dashboard,开发独立部署的跨集群企业级管理台,提供统一多实例监控、细粒度权限控制与死信批量恢复功能。
核心功能多集群/多节点聚合监控、基于角色的访问控制(RBAC)、死信消息重发编排工作流、消息链路端到端追踪可视化、审计日志
目标用户中大型 .NET 企业用户、运维与 SRE 团队
难度/周期中等 · 2 - 3 个月 · 成本:低(基础云服务器用于演示与授权服务开发)
收费模式按集群/节点规模授权 License 订阅
竞争风险开源版本内置 Dashboard 能满足基础诉求,部分企业可能倾向于自行二次开发而不采购。
依据 已验证事实

企业架构与微服务可靠性咨询及技术支持 (Support Subscription)

产品构想为采用 CAP 处理核心交易/财务流程的企业提供生产级保障合同、架构评审、发件箱表性能调优及应急响应服务。
核心功能SLA 响应保障、数据库发件箱大表归档/分表方案设计、高并发背压参数调优、灾备切换与幂等方案落地
目标用户金融、电商、供应链等对数据一致性极度敏感的 .NET 企业
难度/周期中等 · 持续进行(以人天或年度服务协议计) · 成本:极低(主要为人力交付成本)
收费模式年度技术支持订阅费 (Annual Support Contract) 或专家人天咨询费
竞争风险.NET 生态付费意愿在部分区域(如国内中小企业)偏低,依赖独立开发者的品牌号召力与信任度。
依据 数据支持的判断

异构系统一致性集成套件 (Heterogeneous Outbox Connectors)

产品构想开发连接 Java/Go 等异构微服务与 .NET CAP 的专属 SDK 及 CDC (变更数据捕获) 桥接组件,统一企业混合技术栈的事务总线。
核心功能Debezium/CDC 统一协议对接、多语言发件箱消费 SDK、跨技术栈消息追踪与协议兼容层
目标用户技术栈混杂、由 Java/Go 和 .NET 协同开发的中大型企业研发团队
难度/周期高 · 3 - 5 个月 · 成本:低至中等(研发与测试环境开销)
收费模式商业组件授权或源码购买
竞争风险多语言维护成本高,市面存在 Kafka/RabbitMQ 等平台原生更通用的中间件竞争。
依据 AI推测
AI 基于仓库公开数据分析生成,含推测成分,不构成收益承诺。
报告会保存到 个人中心

竞品与相似项目 GitHub Search 真实检索

以上为通过 GitHub 官方 Search API 检索的相似项目,功能差异与优劣势需进一步人工确认,配置 AI 后可生成对比分析。

项目优势与风险

技术成熟度创建于 2016-12-14,近 30 天仍在推送,发布过 77 个 Release
社区活跃Star 7,125 / Fork 1,330 / Issue 9(数据支持,可自行核实)
许可证MIT
主要风险上游项目方向可能变化;同赛道竞争者较多(见竞品表);热度与需求不完全等价

安装与使用

此项目未提供 Docker 镜像,安装步骤以原仓库 README 为准(涉及依赖安装与环境配置,对新手门槛较高)。