You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
|
2 months ago | |
|---|---|---|
| .. | ||
| LINGYUN/Abp/Hangfire/Storage/SqlServer | 2 years ago | |
| FodyWeavers.xml | 2 years ago | |
| FodyWeavers.xsd | 2 years ago | |
| LINGYUN.Abp.Hangfire.Storage.SqlServer.csproj | 2 months ago | |
| README.EN.md | 1 year ago | |
| README.md | 1 year ago | |
README.md
LINGYUN.Abp.Hangfire.Storage.SqlServer
English | 简体中文
1. 介绍
LINGYUN.Abp.Hangfire.Storage.SqlServer 是一个用于配置Hangfire使用SQL Server作为存储的ABP模块。该模块提供了简单的配置方式,让你能够轻松地将SQL Server作为Hangfire的持久化存储。
2. 功能特性
- 简单的SQL Server存储配置
- 支持自定义连接字符串
- 支持SQL Server存储选项配置
- 与ABP配置系统无缝集成
3. 安装
dotnet add package LINGYUN.Abp.Hangfire.Storage.SqlServer
4. 使用方法
- 添加
AbpHangfireSqlServerStorageModule到模块依赖中:
[DependsOn(typeof(AbpHangfireSqlServerStorageModule))]
public class YourModule : AbpModule
{
}
- 在appsettings.json中配置连接字符串和存储选项:
{
"Hangfire": {
"SqlServer": {
"Connection": "Server=localhost;Database=YourDb;Trusted_Connection=True;",
"CommandBatchMaxTimeout": "00:05:00",
"SlidingInvisibilityTimeout": "00:05:00",
"QueuePollInterval": "00:00:00",
"UseRecommendedIsolationLevel": true,
"DisableGlobalLocks": true
}
}
}
5. 配置项
5.1 连接字符串配置
模块会按以下顺序查找连接字符串:
Hangfire:SqlServer:ConnectionConnectionStrings:Default
5.2 存储选项
CommandBatchMaxTimeout: 命令批处理最大超时时间SlidingInvisibilityTimeout: 滑动不可见超时时间QueuePollInterval: 队列轮询间隔UseRecommendedIsolationLevel: 是否使用推荐的隔离级别DisableGlobalLocks: 是否禁用全局锁
6. 依赖项
- Volo.Abp.Hangfire
- Hangfire.SqlServer