你可以使用Hangfire.PostgreSql这个第三方包来设置多个Hangfire实例,以及将它们连接到同一个PostgreSQL数据库。要设置多个Hangfire实例,你需要像这样写代码:
// Configure Hangfire for the first instance
var storageOptions = new PostgreSqlStorageOptions {
SchemaName = "hangfire1"
};
GlobalConfiguration.Configuration.UsePostgreSqlStorage("ConnectionStr...
<未完>点击进入
创作工场 - 内容创作
AI正在思考,请稍等...
- 问题越精准、内容越详细,请勿提交相同标题!

