orchestrator
2023.4
false
- 入门指南
- 要求
- 最佳实践
- 安装
- 正在更新
- 身份服务器
- 对启动错误进行故障排除
重要 :
请注意此内容已使用机器翻译进行了部分本地化。
Orchestrator 安装指南
Last updated 2024年10月3日
升级前
重要提示:
如果您使用 Active Directory (AD) 并计划升级到 2023.4.0,我们强烈建议您直接跳到 2023.4.3 版本,因为 2023.4.0、2023.4.1 和 2023.4.2 会受到 AD 问题的影响。
请务必在从 2023.4 升级到 2023.4 以上的版本之前执行这些步骤。它们有助于确保在升级完成后,您可以立即开始使用,且不会有问题。
-
备份数据库以消除任何数据丢失风险。
-
运行下面的升级前数据库维护脚本。
此脚本会从数据库中删除所有过期或已使用的授权。 这有助于加快[identity].[PersistedGrants]
主键和索引的重新创建,从而加快数据库迁移。DECLARE @Now DATETIME2 = GETUTCDATE() DECLARE @ConsumedGrantsGracePeriod DATETIME2 = DATEADD(hour, -2, @Now) DECLARE @ConsumedDeleted int = 1 DECLARE @ExpiredDeleted int = 1 DECLARE @BatchSize int = 500 DECLARE @ConsumedBatchesDeleted int = 0 DECLARE @ExpiredBatchesDeleted int = 0 SET LOCK_TIMEOUT 0 SET DEADLOCK_PRIORITY LOW WHILE (@ConsumedDeleted=1 OR @ExpiredDeleted=1) BEGIN IF @ConsumedDeleted=1 BEGIN BEGIN TRY DELETE TOP(@BatchSize) FROM [identity].[PersistedGrants] WHERE [ConsumedTime] IS NOT NULL AND [ConsumedTime] < @ConsumedGrantsGracePeriod AND [Type] <> 'reference_token' IF @@ROWCOUNT = 0 SET @ConsumedDeleted=0 ELSE SET @ConsumedBatchesDeleted = @ConsumedBatchesDeleted + 1 END TRY BEGIN CATCH PRINT 'Failed to delete consumed grants' END CATCH END IF @ExpiredDeleted=1 BEGIN BEGIN TRY DELETE TOP(@BatchSize) FROM [identity].[PersistedGrants] WHERE [Expiration] < @Now AND [Type] <> 'reference_token' IF @@ROWCOUNT = 0 SET @ExpiredDeleted=0 ELSE SET @ExpiredBatchesDeleted = @ExpiredBatchesDeleted + 1 END TRY BEGIN CATCH PRINT 'Failed to delete expired grants' END CATCH END PRINT 'Consumed batches deleted: ' + CONVERT(nvarchar(32), @ConsumedBatchesDeleted) PRINT 'Expired batches deleted: ' + CONVERT(nvarchar(32), @ExpiredBatchesDeleted) -- Wait for 10 seconds between deletes IF (@ExpiredDeleted=1 OR @ConsumedDeleted=1) WAITFOR DELAY '00:00:05.000' END
DECLARE @Now DATETIME2 = GETUTCDATE() DECLARE @ConsumedGrantsGracePeriod DATETIME2 = DATEADD(hour, -2, @Now) DECLARE @ConsumedDeleted int = 1 DECLARE @ExpiredDeleted int = 1 DECLARE @BatchSize int = 500 DECLARE @ConsumedBatchesDeleted int = 0 DECLARE @ExpiredBatchesDeleted int = 0 SET LOCK_TIMEOUT 0 SET DEADLOCK_PRIORITY LOW WHILE (@ConsumedDeleted=1 OR @ExpiredDeleted=1) BEGIN IF @ConsumedDeleted=1 BEGIN BEGIN TRY DELETE TOP(@BatchSize) FROM [identity].[PersistedGrants] WHERE [ConsumedTime] IS NOT NULL AND [ConsumedTime] < @ConsumedGrantsGracePeriod AND [Type] <> 'reference_token' IF @@ROWCOUNT = 0 SET @ConsumedDeleted=0 ELSE SET @ConsumedBatchesDeleted = @ConsumedBatchesDeleted + 1 END TRY BEGIN CATCH PRINT 'Failed to delete consumed grants' END CATCH END IF @ExpiredDeleted=1 BEGIN BEGIN TRY DELETE TOP(@BatchSize) FROM [identity].[PersistedGrants] WHERE [Expiration] < @Now AND [Type] <> 'reference_token' IF @@ROWCOUNT = 0 SET @ExpiredDeleted=0 ELSE SET @ExpiredBatchesDeleted = @ExpiredBatchesDeleted + 1 END TRY BEGIN CATCH PRINT 'Failed to delete expired grants' END CATCH END PRINT 'Consumed batches deleted: ' + CONVERT(nvarchar(32), @ConsumedBatchesDeleted) PRINT 'Expired batches deleted: ' + CONVERT(nvarchar(32), @ExpiredBatchesDeleted) -- Wait for 10 seconds between deletes IF (@ExpiredDeleted=1 OR @ConsumedDeleted=1) WAITFOR DELAY '00:00:05.000' END -
将传统文件夹迁移 到新式文件夹,以确保执行不中断。
这些 是您目前在传统文件夹删除流程中可以预期的更改。